mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-03-11 02:12:21 -05:00
Revert "Removed unused upsertCustomer method"
This reverts commit b261c1d61e06e35657741de888fd651329101d69. upsertCustomer method is used to overwrite customer when checkout session is completed.
This commit is contained in:
parent
94301e3c17
commit
b8a17f2be0
1 changed files with 9 additions and 0 deletions
|
@ -119,6 +119,15 @@ module.exports = class MemberRepository {
|
|||
}, options);
|
||||
}
|
||||
|
||||
async upsertCustomer(data) {
|
||||
return await this._StripeCustomer.upsert({
|
||||
customer_id: data.customer_id,
|
||||
member_id: data.member_id,
|
||||
name: data.name,
|
||||
email: data.email
|
||||
});
|
||||
}
|
||||
|
||||
async linkStripeCustomer(data, options) {
|
||||
if (!this._stripeAPIService.configured) {
|
||||
throw new Error('Cannot link Stripe Customer with no Stripe Connection');
|
||||
|
|
Loading…
Add table
Reference in a new issue