working with single upgrade

This commit is contained in:
Shawn Erquhart
2025-02-18 13:24:14 -05:00
parent 0b42ce546f
commit 8473dbc96b
8 changed files with 33 additions and 14 deletions

View File

@@ -7,15 +7,14 @@ import { PREMIUM_PLAN_NAME, PREMIUM_PLUS_PLAN_NAME } from "./seed";
export const polar = new Polar<DataModel>(components.polar);
export const MAX_FREE_TODOS = 5;
export const MAX_PREMIUM_TODOS = 10;
export const MAX_FREE_TODOS = 3;
export const MAX_PREMIUM_TODOS = 6;
export const { generateCheckoutLink } = polar.checkoutApi({
getUserInfo: async (ctx) => {
const user = await ctx.runQuery(api.example.getCurrentUser);
return {
userId: user._id,
email: user.email,
};
},
});