mirror of
https://github.com/fosrl/pangolin.git
synced 2026-03-02 00:36:38 +00:00
Set version when creating sub
This commit is contained in:
@@ -69,7 +69,8 @@ export async function handleSubscriptionCreated(
|
|||||||
? subscription.canceled_at
|
? subscription.canceled_at
|
||||||
: null,
|
: null,
|
||||||
createdAt: subscription.created,
|
createdAt: subscription.created,
|
||||||
type: type
|
type: type,
|
||||||
|
version: 1 // we are hardcoding the initial version when the subscription is created, and then we will increment it on every update
|
||||||
};
|
};
|
||||||
|
|
||||||
await db.insert(subscriptions).values(newSubscription);
|
await db.insert(subscriptions).values(newSubscription);
|
||||||
|
|||||||
Reference in New Issue
Block a user