diff options
author | Emilio Tagua <miloops@gmail.com> | 2010-09-24 17:02:26 -0300 |
---|---|---|
committer | Emilio Tagua <miloops@gmail.com> | 2010-09-27 11:19:24 -0300 |
commit | 023c2020b3f94dadb86ead782c07006732d9ab56 (patch) | |
tree | c57f7292f3ffb5149d4cc619ceb42c3dfa7b8236 /actionpack | |
parent | bb71f182ddf53333d4b3cabe111d7ba58d8cbe23 (diff) | |
download | rails-023c2020b3f94dadb86ead782c07006732d9ab56.tar.gz rails-023c2020b3f94dadb86ead782c07006732d9ab56.tar.bz2 rails-023c2020b3f94dadb86ead782c07006732d9ab56.zip |
Initialize @_routes if not defined yet, avoiding more warnings.
Diffstat (limited to 'actionpack')
-rw-r--r-- | actionpack/lib/action_controller/metal/url_for.rb | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/actionpack/lib/action_controller/metal/url_for.rb b/actionpack/lib/action_controller/metal/url_for.rb index 85c6b0a9b5..f43fc3f609 100644 --- a/actionpack/lib/action_controller/metal/url_for.rb +++ b/actionpack/lib/action_controller/metal/url_for.rb @@ -6,6 +6,7 @@ module ActionController def url_options options = {} + @_routes ||= nil if _routes.equal?(env["action_dispatch.routes"]) options[:script_name] = request.script_name.dup end |