Method: DataMapper::Associations::Relationship#source_scope

Defined in:
lib/dm-core/associations/relationship.rb

#source_scope(source) ⇒ Hash

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.

Returns a hash of conditions that scopes query that fetches target object

Returns:

  • (Hash)

    Hash of conditions that scopes query



142
143
144
# File 'lib/dm-core/associations/relationship.rb', line 142

def source_scope(source)
  { inverse => source }
end