MCPcopy Create free account
hub / github.com/Linen-dev/linen.dev / downgradeAccount

Function downgradeAccount

apps/web/pages/api/webhook/stripe.ts:28–35  ·  view source on GitHub ↗
(communityId: string)

Source from the content-addressed store, hash-verified

26}
27
28async function downgradeAccount(communityId: string) {
29 return prisma.accounts.update({
30 where: { id: communityId },
31 data: {
32 premium: false,
33 },
34 });
35}
36
37async function getCommunityId(event: any) {
38 const { customer: customerId } = event.data.object as any;

Callers 1

handlerFunction · 0.85

Calls 1

updateMethod · 0.45

Tested by

no test coverage detected