Skip to content

There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use.

fix(server): should clean bill date if lifetime subscription (#7577)

forehalo14fbeb7879f4
diff --git a/packages/backend/server/src/plugins/payment/service.ts b/packages/backend/server/src/plugins/payment/service.ts
index be7bc42793..ba4bcfb9f6 100644
--- a/packages/backend/server/src/plugins/payment/service.ts
+++ b/packages/backend/server/src/plugins/payment/service.ts
@@ -573,7 +573,9 @@ export class SubscriptionService {
stripeSubscriptionId: null,
status: SubscriptionStatus.Active,
recurring: SubscriptionRecurring.Lifetime,
+ start: new Date(),
end: null,
+ nextBillAt: null,
},
});
@@ -590,8 +592,8 @@ export class SubscriptionService {
stripeSubscriptionId: null,
plan: invoice.plan,
recurring: invoice.recurring,
- end: null,
start: new Date(),
+ end: null,
status: SubscriptionStatus.Active,
nextBillAt: null,
},