aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_dispatch/routing/routes_proxy.rb
diff options
context:
space:
mode:
Diffstat (limited to 'actionpack/lib/action_dispatch/routing/routes_proxy.rb')
-rw-r--r--actionpack/lib/action_dispatch/routing/routes_proxy.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/actionpack/lib/action_dispatch/routing/routes_proxy.rb b/actionpack/lib/action_dispatch/routing/routes_proxy.rb
index f7d5f6397d..73af5920ed 100644
--- a/actionpack/lib/action_dispatch/routing/routes_proxy.rb
+++ b/actionpack/lib/action_dispatch/routing/routes_proxy.rb
@@ -16,6 +16,10 @@ module ActionDispatch
end
end
+ def respond_to?(method, include_private = false)
+ super || routes.url_helpers.respond_to?(method)
+ end
+
def method_missing(method, *args)
if routes.url_helpers.respond_to?(method)
self.class.class_eval <<-RUBY, __FILE__, __LINE__ + 1