class Pay::Stripe::Webhooks::AccountUpdated

Public Instance Methods

call(event) click to toggle source
# File lib/pay/stripe/webhooks/account_updated.rb, line 5
def call(event)
  object = event.data.object

  merchant = Pay::Merchant.find_by(processor: :stripe, processor_id: object.id)
  return unless merchant

  merchant.update(onboarding_complete: object.charges_enabled)
end