Fix saving price and currency (#3168)

pull/3178/head
alannnc 2022-06-27 20:31:25 -06:00 committed by GitHub
parent 52759333fd
commit e3e1de3c11
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 2 deletions

View File

@ -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,