diff options
author | Andrew White <andyw@pixeltrix.co.uk> | 2010-11-09 05:10:39 +0000 |
---|---|---|
committer | Andrew White <andyw@pixeltrix.co.uk> | 2010-11-09 05:24:10 +0000 |
commit | ef46b9f21a275249d1b0cf9926ffb879b0ae2c44 (patch) | |
tree | aa2f8a092c0718ac66778de55f63470465847736 /actionpack/lib | |
parent | 4e0477c9b75683372f662a614ae91b158120ebe8 (diff) | |
download | rails-ef46b9f21a275249d1b0cf9926ffb879b0ae2c44.tar.gz rails-ef46b9f21a275249d1b0cf9926ffb879b0ae2c44.tar.bz2 rails-ef46b9f21a275249d1b0cf9926ffb879b0ae2c44.zip |
Strip regexp anchors from rake routes output [#5934 state:resolved]
Diffstat (limited to 'actionpack/lib')
-rw-r--r-- | actionpack/lib/action_dispatch/routing/route.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/actionpack/lib/action_dispatch/routing/route.rb b/actionpack/lib/action_dispatch/routing/route.rb index f91a48e16c..08a8408f25 100644 --- a/actionpack/lib/action_dispatch/routing/route.rb +++ b/actionpack/lib/action_dispatch/routing/route.rb @@ -30,7 +30,8 @@ module ActionDispatch if method = conditions[:request_method] case method when Regexp - method.source.upcase + source = method.source.upcase + source =~ /\A\^[-A-Z|]+\$\Z/ ? source[1..-2] : source else method.to_s.upcase end |