提交 5f00f137 编写于 作者: C Carlos Antonio da Silva

Set values instead of building hashes with single values for merging

上级 ce06d57e
......@@ -168,7 +168,7 @@ def normalize_defaults!
end
def normalize_conditions!
@conditions.merge!(:path_info => path)
@conditions[:path_info] = path
constraints.each do |key, condition|
unless segment_keys.include?(key) || key == :controller
......@@ -196,7 +196,7 @@ def normalize_conditions!
if via = options[:via]
list = Array(via).map { |m| m.to_s.dasherize.upcase }
@conditions.merge!(:request_method => list)
@conditions[:request_method] = list
end
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册