Merge pull request 'Fix the backend build against hono's narrowed route param type.' (#34) from dev into main
Reviewed-on: #34
This commit was merged in pull request #34.
This commit is contained in:
@@ -84,7 +84,8 @@ function toDoorAttendee(
|
||||
};
|
||||
}
|
||||
|
||||
async function loadEvent(eventId: string) {
|
||||
async function loadEvent(eventId: string | undefined) {
|
||||
if (!eventId) return null;
|
||||
const event = await dbGet<any>(
|
||||
(db as any).select().from(events).where(eq((events as any).id, eventId))
|
||||
);
|
||||
|
||||
@@ -667,7 +667,7 @@ paymentsRouter.post('/:id/send-reminder', requireAuth(['admin', 'organizer']), a
|
||||
}
|
||||
|
||||
try {
|
||||
const result = await emailService.sendPaymentReminder(id);
|
||||
const result = await emailService.sendPaymentReminder(payment.id);
|
||||
|
||||
if (result.success) {
|
||||
const now = getNow();
|
||||
|
||||
@@ -1174,7 +1174,7 @@ ticketsRouter.post('/:id/mark-paid', requireAuth(['admin', 'organizer', 'staff']
|
||||
|
||||
// Send confirmation emails asynchronously (don't block the response)
|
||||
Promise.all([
|
||||
emailService.sendBookingConfirmation(id),
|
||||
emailService.sendBookingConfirmation(ticket.id),
|
||||
payment ? emailService.sendPaymentReceipt(payment.id) : Promise.resolve(),
|
||||
]).catch(err => {
|
||||
console.error('[Email] Failed to send confirmation emails:', err);
|
||||
|
||||
Reference in New Issue
Block a user