Module: Mongoid::Association::Referenced::Syncable::ClassMethods

Defined in:
lib/mongoid/association/referenced/syncable.rb

Instance Method Summary collapse

Instance Method Details

#_synced(association) ⇒ Object

Set up the syncing of many to many foreign keys.

Examples:

Set up the syncing.

Person._synced(association)

Parameters:



99
100
101
102
103
104
# File 'lib/mongoid/association/referenced/syncable.rb', line 99

def _synced(association)
  return if association.forced_nil_inverse?

  synced_save(association)
  synced_destroy(association)
end