Module: LazyModelConst

Includes:
LazyConst
Defined in:
lib/lazy_model_const.rb

Defined Under Namespace

Modules: ExtendedModelMixins

Instance Method Summary collapse

Instance Method Details

#lazy_model_const(name, attrs = {}) ⇒ Object



5
6
7
8
9
# File 'lib/lazy_model_const.rb', line 5

def lazy_model_const(name, attrs = {})
  lazy_const name do
    find_or_create_by_name(attrs)
  end
end