method
prepare
v8.1.1 -
Show latest stable
- Class:
ActiveRecord::Store::IndifferentHashAccessor
prepare(object, attribute)public
No documentation available.
# File activerecord/lib/active_record/store.rb, line 277
def self.prepare(object, attribute)
store_object = object.public_send(attribute)
unless store_object.is_a?(ActiveSupport::HashWithIndifferentAccess)
store_object = IndifferentCoder.as_indifferent_hash(store_object)
object.public_send :"#{attribute}=", store_object
end
store_object
end