Method: Entangled::Model::ClassMethods#create_hook

Defined in:
lib/entangled/model.rb

#create_hook(name) ⇒ Object

Creates callbacks in the extented model

[View source]

59
60
61
# File 'lib/entangled/model.rb', line 59

def create_hook(name)
  send :"after_#{name}", -> { publish(name) }
end