Module: Halogen::Collection::InstanceMethods

Defined in:
lib/halogen/collection.rb

Overview

:nodoc:

Instance Method Summary collapse

Instance Method Details

#embed?(key) ⇒ true, false

Ensure that the primary collection is always embedded

Parameters:

  • key (String)

    the embed key to check

Returns:

  • (true, false)

    whether the given key should be embedded


39
40
41
# File 'lib/halogen/collection.rb', line 39

def embed?(key)
  key == self.class.collection_name
end