diff options
author | Derek Watson <watson@dcw.ca> | 2013-04-11 22:12:19 -0400 |
---|---|---|
committer | Andrew White <andyw@pixeltrix.co.uk> | 2013-04-18 17:12:40 +0100 |
commit | 6183e1a460ccab6df1d07c3e99e98b61b2cc450b (patch) | |
tree | d585a05a0202f30b2e51d27d11e59fae20b5c320 /actionpack/lib/action_dispatch/journey | |
parent | 296830ed0f8732c6779dcdfed0f0e3d59947e47c (diff) | |
download | rails-6183e1a460ccab6df1d07c3e99e98b61b2cc450b.tar.gz rails-6183e1a460ccab6df1d07c3e99e98b61b2cc450b.tar.bz2 rails-6183e1a460ccab6df1d07c3e99e98b61b2cc450b.zip |
Passing subdomain: '' to url_for removes the subdomain (instead of adding a leading .)
Adding a boolean route constraint checks for presence/absence of request property
Diffstat (limited to 'actionpack/lib/action_dispatch/journey')
-rw-r--r-- | actionpack/lib/action_dispatch/journey/route.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/actionpack/lib/action_dispatch/journey/route.rb b/actionpack/lib/action_dispatch/journey/route.rb index 6fda085681..50e1853094 100644 --- a/actionpack/lib/action_dispatch/journey/route.rb +++ b/actionpack/lib/action_dispatch/journey/route.rb @@ -102,6 +102,10 @@ module ActionDispatch value === request.send(method).to_s when Array value.include?(request.send(method)) + when TrueClass + request.send(method).present? + when FalseClass + request.send(method).blank? else value === request.send(method) end |