Sha256: fe2c045f29a7e1a3ac46beacd30b0eb77f71e9bee0074c14d5c14787b2da0241

Contents?: true

Size: 313 Bytes

Versions: 4

Compression:

Stored size: 313 Bytes

Contents

module Approval
  module FormNotifiable
    extend ActiveSupport::Concern

    private

    def instrument(operation, payload = {}, &block)
      payload.merge!(request: request, user: user, reason: reason)
      ActiveSupport::Notifications.instrument("#{operation}.approval", payload, &block)
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
approval-0.7.1 app/models/concerns/approval/form_notifiable.rb
approval-0.7.0 app/models/concerns/approval/form_notifiable.rb
approval-0.6.1 app/models/concerns/approval/form_notifiable.rb
approval-0.6.0 app/models/concerns/approval/form_notifiable.rb