aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack
diff options
context:
space:
mode:
authorkennyj <kennyj@gmail.com>2013-09-19 12:58:11 +0900
committerkennyj <kennyj@gmail.com>2013-09-22 01:10:31 +0900
commit4f0f5fc8b9bdc13f0aa37012443f6ea3c03a60e0 (patch)
tree0e49271f24e9d9054b0eb59a3a13705ac8061709 /actionpack
parent32e23884cc424755531acc235228a7b2d4554fe1 (diff)
downloadrails-4f0f5fc8b9bdc13f0aa37012443f6ea3c03a60e0.tar.gz
rails-4f0f5fc8b9bdc13f0aa37012443f6ea3c03a60e0.tar.bz2
rails-4f0f5fc8b9bdc13f0aa37012443f6ea3c03a60e0.zip
[ci skip] Add some comment about downcase url encoded string.
Diffstat (limited to 'actionpack')
-rw-r--r--actionpack/lib/action_dispatch/journey/router/utils.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/actionpack/lib/action_dispatch/journey/router/utils.rb b/actionpack/lib/action_dispatch/journey/router/utils.rb
index 810f86db2f..1edf86cd88 100644
--- a/actionpack/lib/action_dispatch/journey/router/utils.rb
+++ b/actionpack/lib/action_dispatch/journey/router/utils.rb
@@ -7,11 +7,13 @@ module ActionDispatch
# Normalizes URI path.
#
# Strips off trailing slash and ensures there is a leading slash.
+ # Also converts downcase url encoded string to uppercase.
#
# normalize_path("/foo") # => "/foo"
# normalize_path("/foo/") # => "/foo"
# normalize_path("foo") # => "/foo"
# normalize_path("") # => "/"
+ # normalize_path("/%ab") # => "/%AB"
def self.normalize_path(path)
path = "/#{path}"
path.squeeze!('/')