From e049319c778e638e090309e93daee3d2fe087b15 Mon Sep 17 00:00:00 2001 From: Prathamesh Sonpatki Date: Fri, 6 Mar 2015 17:18:46 +0530 Subject: Fix documentation of url_for module [ci skip] - The request needs to be instance of ActionDispatch::Request or an object that responds to host, optional_port, protocol and symbolized_path_parameter. - This documentation was correctly added in https://github.com/rails/rails/commit/e3b3f416b57f5642ea25078485f7e9394ad04526 but was changed to https://github.com/rails/rails/commit/e1ceae576e3911f3e6708b5d19a0e3ef63769eb7. - Fixes #16160. --- actionpack/lib/action_controller/metal/url_for.rb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'actionpack') diff --git a/actionpack/lib/action_controller/metal/url_for.rb b/actionpack/lib/action_controller/metal/url_for.rb index 572d1770f7..fbaa90d521 100644 --- a/actionpack/lib/action_controller/metal/url_for.rb +++ b/actionpack/lib/action_controller/metal/url_for.rb @@ -4,7 +4,10 @@ module ActionController # # In addition to AbstractController::UrlFor, this module accesses the HTTP layer to define # url options like the +host+. In order to do so, this module requires the host class - # to implement +env+ and +request+, which need to be a Rack-compatible. + # to implement +env+ which needs to be Rack-compatible and +request+ + # which is either instance of +ActionDispatch::Request+ or an object + # that responds to host, optional_port, protocol and + # symbolized_path_parameter methods. # # class RootUrl # include ActionController::UrlFor -- cgit v1.2.3