Method: ROM::Factory::TupleEvaluator#persist_associations

Defined in:
lib/rom/factory/tuple_evaluator.rb

#persist_associations(tuple, parent, traits = []) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



109
110
111
112
113
114
# File 'lib/rom/factory/tuple_evaluator.rb', line 109

def persist_associations(tuple, parent, traits = [])
  assoc_names(traits).each do |name|
    assoc = tuple[name]
    assoc.call(parent, persist: true) if assoc.is_a?(Proc)
  end
end