mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
this should never return nil, so no use for "try"
This commit is contained in:
parent
6cbe4223a7
commit
62a86748ae
1 changed files with 1 additions and 1 deletions
|
@ -175,7 +175,7 @@ module ActionController #:nodoc:
|
|||
private
|
||||
def normalize!(path)
|
||||
path << 'index' if path[-1] == ?/
|
||||
path << ".#{extension}" if extension and !path.split('?').first.try(:ends_with?, ".#{extension}")
|
||||
path << ".#{extension}" if extension and !path.split('?').first.ends_with?(".#{extension}")
|
||||
URI.parser.unescape(path)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue