提交 c3346b31 编写于 作者: A Aaron Patterson

Merge pull request #2218 from guilleiguaran/avoid-map-chaining

Remove unneccesary map chaining
......@@ -6,7 +6,7 @@
require 'yaml'
YAML.add_builtin_type("omap") do |type, val|
ActiveSupport::OrderedHash[val.map(&:to_a).map(&:first)]
ActiveSupport::OrderedHash[val.map{ |v| v.to_a.first }]
end
module ActiveSupport
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册