add support for routes as a callable function