class Delocalize::Parameters
Public Instance Methods
[](key)
click to toggle source
Calls superclass method
# File lib/delocalize/parameters.rb, line 9 def [](key) convert_hashes_to_parameters(key, super) end
Private Instance Methods
convert_hashes_to_parameters(key, value)
click to toggle source
# File lib/delocalize/parameters.rb, line 15 def convert_hashes_to_parameters(key, value) if value.is_a?(self.class) || !value.is_a?(Hash) value else # convert on first access self[key] = self.class.new(value) end end