Fix type error
This commit is contained in:
parent
ec5769abb2
commit
51e127f293
|
@ -57,12 +57,7 @@ export const deleteTeamFromStripe = async (teamId: number) => {
|
|||
select: { stripeCustomerId: true },
|
||||
});
|
||||
|
||||
if (!stripeCustomerId) {
|
||||
throw new Error("Team not found");
|
||||
return;
|
||||
}
|
||||
|
||||
if (stripeCustomerId) {
|
||||
if (stripeCustomerId?.stripeCustomerId) {
|
||||
await stripe.customers.del(stripeCustomerId.stripeCustomerId);
|
||||
return;
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue
Block a user