Module: Alchemy::Element::Definitions

Extended by:
ActiveSupport::Concern
Included in:
Alchemy::Element
Defined in:
app/models/alchemy/element/definitions.rb

Overview

Module concerning element definitions

Defined Under Namespace

Modules: ClassMethods

Instance Method Summary collapse

Instance Method Details

#definitionObject

The definition of this element.



43
44
45
46
47
48
49
50
51
# File 'app/models/alchemy/element/definitions.rb', line 43

def definition
  if (definition = self.class.definition_by_name(name))
    definition
  else
    log_warning "Could not find element definition for #{name}. " \
                "Please check your elements.yml file!"
    {}
  end
end