fix update env API_KEY_ prefix default to cal_

pull/2277/head
Agusti Fernandez Pardo 2022-04-14 20:35:37 +02:00
parent ac0133ded2
commit 8f3acdcbab
2 changed files with 4 additions and 1 deletions

View File

@ -83,6 +83,9 @@ NEXT_PUBLIC_STRIPE_PRO_PLAN_PRODUCT=
NEXT_PUBLIC_STRIPE_PRO_PLAN_PRICE=
NEXT_PUBLIC_STRIPE_PREMIUM_PLAN_PRICE=
NEXT_PUBLIC_STRIPE_FREE_PLAN_PRICE=
# Use for internal Public API Keys and optional
API_KEY_PREFIX=cal_
# ***********************************************************************************************************
# - E-MAIL SETTINGS *****************************************************************************************

View File

@ -37,7 +37,7 @@ export const apiKeysRouter = createProtectedRouter()
hashedKey: hashedApiKey,
},
});
const prefixedApiKey = `${process.env.API_KEY_PREFIX ?? "pt_secret_"}${apiKey}`;
const prefixedApiKey = `${process.env.API_KEY_PREFIX ?? "cal_"}${apiKey}`;
return prefixedApiKey;
},
})