Method: ActionDispatch::Routing::Mapper::Mapping.normalize_path
- Defined in:
- actionpack/lib/action_dispatch/routing/mapper.rb
.normalize_path(path, format) ⇒ Object
116 117 118 119 120 121 122 123 124 125 126 |
# File 'actionpack/lib/action_dispatch/routing/mapper.rb', line 116 def self.normalize_path(path, format) path = Mapper.normalize_path(path) if format == true "#{path}.:format" elsif optional_format?(path, format) "#{path}(.:format)" else path end end |