Sha256: 21be8f896e10bac47a6636a264c957d436be7922ab98b9b83f9dcc660f3f0696

Contents?: true

Size: 302 Bytes

Versions: 2

Compression:

Stored size: 302 Bytes

Contents

module Yaps
  # Handles creation of Activities upon destruction and update of tracked model.
  module Creation
    extend ActiveSupport::Concern

    included do
      after_create do
        publish(:"#{ActiveSupport::Inflector.underscore(self.class.name)}_created", self)
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
yaps-0.1.0 lib/yaps/actions/creation.rb
yaps-0.0.2 lib/yaps/actions/creation.rb