提交 280e76e6 编写于 作者: A Aaron Patterson

only add the optiosn if they are not empty

I think this is wrong, but it gets the build passing for now. We should
always add options, but we need to make more guarantees about how the
underlying url helper is called
上级 b44bfa4c
......@@ -135,7 +135,9 @@ def polymorphic_url(record_or_hash_or_array, options = {})
named_route = build_named_route_call(record_or_hash_or_array, record, inflection, options)
url_options = options.except(:action, :routing_type)
args << url_options
unless url_options.empty?
args << url_options
end
args.collect! { |a| convert_to_model(a) }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册