Apply suggestions from code review

payment-booking-requested-webhook
Hariom Balhara 2023-09-07 13:05:01 +05:30 committed by GitHub
parent 1cd03ea0b9
commit c4d4dbd2b5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 0 additions and 5 deletions

View File

@ -2236,7 +2236,6 @@ async function handler(
!originalRescheduledBooking?.paid &&
!!booking;
console.log("Booking requires payment", bookingRequiresPayment, paymentAppData);
if (!isConfirmedByDefault && noEmail !== true && !bookingRequiresPayment) {
await sendOrganizerRequestEmail({ ...evt, additionalNotes });
await sendAttendeeRequestEmail({ ...evt, additionalNotes }, attendeesList[0]);

View File

@ -44,9 +44,6 @@ async function getEventType(id: number) {
}
async function getBooking(bookingId: number) {
log.silly("getBooking", {
bookingId,
});
const booking = await prisma.booking.findUnique({
where: {
id: bookingId,
@ -228,7 +225,6 @@ export async function handlePaymentSuccess(event: Stripe.Event) {
await prisma.$transaction([paymentUpdate, bookingUpdate]);
if (!isConfirmed) {
//TODO: Test an event that requires confirmation conditionally
if (!requiresConfirmation) {
await handleConfirmation({
user: userWithCredentials,