diff --git a/src/main/ipc-handlers/tables.ts b/src/main/ipc-handlers/tables.ts index f122a128..ceb09373 100644 --- a/src/main/ipc-handlers/tables.ts +++ b/src/main/ipc-handlers/tables.ts @@ -221,7 +221,7 @@ export default (connections: Record) => { .update({ [params.field]: `= ${escapedParam}` }) .schema(params.schema) .from(params.table) - .where({ [params.primary]: `= ${sqlEscaper(id)}` }) + .where({ [params.primary]: `= ${typeof id === 'string' ? sqlEscaper(id) : id}` }) .limit(1) .run(); }