From 217f069085cfc11330820c1affa24308acde7b6c Mon Sep 17 00:00:00 2001 From: Fabien 'egg' O'Carroll Date: Mon, 23 Nov 2020 21:19:27 +0000 Subject: [PATCH] Included cancellation_reason in subscription serialization (#12411) refs #12403 This new property needed to be exposed in serialization so that Ghost-Admin can use it via the API. --- core/server/models/stripe-customer-subscription.js | 1 + 1 file changed, 1 insertion(+) diff --git a/core/server/models/stripe-customer-subscription.js b/core/server/models/stripe-customer-subscription.js index 6ad94664e2..5134b581fc 100644 --- a/core/server/models/stripe-customer-subscription.js +++ b/core/server/models/stripe-customer-subscription.js @@ -39,6 +39,7 @@ const StripeCustomerSubscription = ghostBookshelf.Model.extend({ start_date: defaultSerializedObject.start_date, default_payment_card_last4: defaultSerializedObject.default_payment_card_last4, cancel_at_period_end: defaultSerializedObject.cancel_at_period_end, + cancellation_reason: defaultSerializedObject.cancellation_reason, current_period_end: defaultSerializedObject.current_period_end }; }