cartodb/config/initializers/hash.rb

7 lines
112 B
Ruby
Raw Permalink Normal View History

2020-06-15 10:58:47 +08:00
class Hash
def convert_nulls
self.inject({}){|h,(k,v)| h[k] = (v == "null" ? nil : v); h }
end
end