diff --git a/backend/mobile/scanLogs.route.ts b/backend/mobile/scanLogs.route.ts index 730999d..7214c3a 100644 --- a/backend/mobile/scanLogs.route.ts +++ b/backend/mobile/scanLogs.route.ts @@ -12,14 +12,14 @@ router.post("/", async (req, res) => { const newLog = await db .insert(scanLog) .values({ - scannerId: body.scannerId, - message: body.message, - prompt: body.prompt, - commandDescription: body.commandDescription, - status: body.status, - lines: body.lines, - user: body.user, - runningNumber: body.runningNumber, + scannerId: body.scannerId ?? "", + message: body.message ?? "", + prompt: body.prompt ?? "", + commandDescription: body.commandDescription ?? "", + status: body.status ?? "", + lines: body.lines ?? "", + user: body.user ?? "", + runningNumber: body.runningNumber ?? "", }) .returning();