Fix saving price and currency (#3168)

This commit is contained in:
alannnc authored and GitHub committed 2022-06-27 20:31:25 -06:00
1 parent 52759333fd
commit e3e1de3c11
1 file changed
+1 -2
@@ -266,7 +266,6 @@ export const eventTypesRouter = createProtectedRouter()
users,
id,
hashedLink,
price,
...rest
} = input;
assertValidUrl(input.successRedirectUrl);
@@ -316,7 +315,7 @@ export const eventTypesRouter = createProtectedRouter()
};
}
if (price) {
if (input?.price) {
const paymentCredential = await ctx.prisma.credential.findFirst({
where: {
userId: ctx.user.id,