コード例 #1
0
    private async Task HandleCustomerSubscriptionUpdatedEvent(string json)
    {
        var paymentHandlerEvent = _paymentHandlerEventService.FromJson(json);
        var cancelAtPeriodEnd   = _paymentHandlerSubscription.GetCancelAtPeriodEnd(paymentHandlerEvent.SubscriptionId);

        if (cancelAtPeriodEnd)
        {
            await HandleCustomerSubscriptionCancelledAtPeriodEnd(json);
        }
    }
コード例 #2
0
        private async Task HandleCustomerSubscriptionUpdatedEvent(string json)
        {
            var subscriptionId    = _paymentHandlerEvent.GetSubscriptionId(json);
            var cancelAtPeriodEnd = _paymentHandlerSubscription.GetCancelAtPeriodEnd(subscriptionId);

            if (cancelAtPeriodEnd)
            {
                await HandleCustomerSubscriptionCancelledAtPeriodEnd(json);
            }
        }