Class: Pay::Webhooks::Delegator::NotificationAdapter

Inherits:
Object
  • Object
show all
Defined in:
lib/pay/webhooks/delegator.rb

Overview

Strips down to event data only

Instance Method Summary collapse

Constructor Details

#initialize(subscriber) ⇒ NotificationAdapter

Returns a new instance of NotificationAdapter.


44
45
46
# File 'lib/pay/webhooks/delegator.rb', line 44

def initialize(subscriber)
  @subscriber = subscriber
end

Instance Method Details

#call(*args) ⇒ Object


48
49
50
51
# File 'lib/pay/webhooks/delegator.rb', line 48

def call(*args)
  payload = args.last
  @subscriber.call(payload)
end