check current route rails code example Example: check current route rails current_uri = request.env['PATH_INFO']