From ab05998b581b56802e4f6abc59441f65a3cfee25 Mon Sep 17 00:00:00 2001 From: pac7 <47831526-pac7@users.noreply.replit.com> Date: Tue, 7 Oct 2025 15:37:50 +0000 Subject: [PATCH] Improve logging and update development server port Add error handling for notification log insertion and change Vite dev server port from 8080 to 5000. Replit-Commit-Author: Agent Replit-Commit-Session-Id: 853a87ae-e13d-4762-9a69-fbd3990ed527 Replit-Commit-Checkpoint-Type: intermediate_checkpoint --- src/lib/notificationService.ts | 6 +++++- vite.config.ts | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/lib/notificationService.ts b/src/lib/notificationService.ts index 620991f4..7bce1bc2 100644 --- a/src/lib/notificationService.ts +++ b/src/lib/notificationService.ts @@ -258,7 +258,7 @@ class NotificationService { .eq('workflow_id', log.workflowId) .single(); - await supabase.from('notification_logs').insert({ + const { error: logError } = await supabase.from('notification_logs').insert({ user_id: log.userId, template_id: template?.id, novu_transaction_id: log.transactionId, @@ -266,6 +266,10 @@ class NotificationService { status: 'sent', payload: log.payload, }); + + if (logError) { + console.error('Error inserting notification log:', logError); + } } catch (error) { console.error('Error logging notification:', error); } diff --git a/vite.config.ts b/vite.config.ts index 4102c698..54f69fe3 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -7,7 +7,7 @@ import { componentTagger } from "lovable-tagger"; export default defineConfig(({ mode }) => ({ server: { host: "::", - port: 8080, + port: 5000, }, plugins: [react(), mode === "development" && componentTagger()].filter(Boolean), resolve: {