Insert returning: partial return not working

After inserting, I'm attempting to return the generated uuid to ensure that it worked, but when I do the following, I'm getting and error saying: Expected 0 arguments, but got 1.ts(2554). In the schema, the id field is a uuid and does have the defaultRandom added to it. Here's my insert;
const [{ id }] = await this.db
.insert(authUser)
.values({
...props,
createdAt: new Date().getTime()
})
.onConflictDoNothing()
.returning({ id: authUser.id });
const [{ id }] = await this.db
.insert(authUser)
.values({
...props,
createdAt: new Date().getTime()
})
.onConflictDoNothing()
.returning({ id: authUser.id });
1 Reply
Luci
LuciOP5mo ago
Fixed it.
Want results from more Discord servers?
Add your server