Module: AssociateJsonb::AttributeMethods::Read

Extended by:
ActiveSupport::Concern
Defined in:
lib/associate_jsonb/attribute_methods/read.rb

Instance Method Summary collapse

Instance Method Details

#_fetch_attribute(attr_name, &block) ⇒ Object

:nodoc



9
10
11
12
# File 'lib/associate_jsonb/attribute_methods/read.rb', line 9

def _fetch_attribute(attr_name, &block) # :nodoc
  sync_with_transaction_state if @transaction_state&.finalized?
  @attributes.fetch(attr_name.to_s, &block)
end