Sha256: d3d400532df33a378e1eae062bb86ee4e3d2fd72fae92ce3fe7d78056345f50b

Contents?: true

Size: 585 Bytes

Versions: 33

Compression:

Stored size: 585 Bytes

Contents

# A subscription's first authorized transaction is created, or a successful transaction moves a subscription from the Past Due status to the Active status. Subscriptions with trial periods will not trigger this notification when they move from the trial period into the first billing cycle.

module Pay
  module Braintree
    module Webhooks
      class SubscriptionWentActive
        def call(event)
          subscription = event.subscription
          return if subscription.nil?

          Pay::Braintree::Subscription.sync(subscription.id)
        end
      end
    end
  end
end

Version data entries

33 entries across 33 versions & 1 rubygems

Version Path
pay-8.3.0 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-8.2.2 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-8.2.1 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-8.2.0 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-8.1.3 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-8.1.2 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-8.1.1 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-8.1.0 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-8.0.0 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-7.3.0 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-7.2.1 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-7.1.1 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-7.1.0 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-7.0.0 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-6.8.1 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-6.8.0 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-6.7.2 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-6.7.1 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-6.7.0 lib/pay/braintree/webhooks/subscription_went_active.rb
pay-6.6.1 lib/pay/braintree/webhooks/subscription_went_active.rb