aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib
diff options
context:
space:
mode:
authorJorge Bejar <jorge@wyeworks.com>2015-07-20 14:07:49 -0300
committerJorge Bejar <jorge@wyeworks.com>2015-12-09 10:53:45 -0300
commit02c5c0d1565318668f8d3161374c4f4c269e6d33 (patch)
tree694181268db03e140d5c183125753314d713d49d /actionpack/lib
parentd879c0ec5a7eebf9eed01c84c8f95566be2aedf4 (diff)
downloadrails-02c5c0d1565318668f8d3161374c4f4c269e6d33.tar.gz
rails-02c5c0d1565318668f8d3161374c4f4c269e6d33.tar.bz2
rails-02c5c0d1565318668f8d3161374c4f4c269e6d33.zip
Improve regexp in AC::Http::Parameters
Diffstat (limited to 'actionpack/lib')
-rw-r--r--actionpack/lib/action_dispatch/http/parameters.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_dispatch/http/parameters.rb b/actionpack/lib/action_dispatch/http/parameters.rb
index 4084d78f49..9d450beae5 100644
--- a/actionpack/lib/action_dispatch/http/parameters.rb
+++ b/actionpack/lib/action_dispatch/http/parameters.rb
@@ -77,7 +77,7 @@ module ActionDispatch
def format_from_path_extension
path = @env['action_dispatch.original_path'] || @env['PATH_INFO']
- if match = path && path.match(/\.(\w+)$/)
+ if match = path && path.match(/\.(\w+)\z/)
match.captures.first
end
end