Support directories in custom routes