Skip to content

Commit 3fdd3dd

Browse files
committed
more consistent
1 parent 641255a commit 3fdd3dd

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

src/sql/postgres.zig

+1-4
Original file line numberDiff line numberDiff line change
@@ -366,15 +366,12 @@ pub const PostgresSQLQuery = struct {
366366
return;
367367
}
368368

369-
const instance = globalObject.createErrorInstance("Failed to bind query: {s}", .{@errorName(err)});
370-
371-
// TODO: error handling
372369
const vm = JSC.VirtualMachine.get();
373370
const function = vm.rareData().postgresql_context.onQueryRejectFn.get().?;
374371
const event_loop = vm.eventLoop();
375372
event_loop.runCallback(function, globalObject, thisValue, &.{
376373
targetValue,
377-
instance,
374+
postgresErrorToJS(globalObject, null, err),
378375
queries_array,
379376
});
380377
}

0 commit comments

Comments
 (0)