Fix issue with Ruby 1.8.7 which did not allow for the return in an each_pair of the hash
This commit is contained in:
parent
7021b1f55c
commit
419f51bdd9
1 changed files with 2 additions and 2 deletions
|
@ -31,8 +31,8 @@ Will return:
|
|||
result = value.collect { |i| i.is_a?(String) ? i.upcase : i }
|
||||
elsif value.is_a?(Hash)
|
||||
result = {}
|
||||
result << value.each_pair do |k, v|
|
||||
return {k.upcase => v.collect! { |p| p.upcase }}
|
||||
value.each_pair do |k, v|
|
||||
result.merge!({k.upcase => v.collect! { |p| p.upcase }})
|
||||
end
|
||||
else
|
||||
result = value.upcase
|
||||
|
|
Loading…
Reference in a new issue