0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2025-02-03 22:29:08 -05:00

chore: remove as any on seed values

This commit is contained in:
bholmesdev 2024-02-05 16:40:48 -05:00
parent 25f940fe49
commit 1ef45b1a09

View file

@ -51,15 +51,8 @@ export async function setupDbTables({
async seed({ table }, values) {
const result = Array.isArray(values)
? // TODO: fix values typing once we can infer fields type correctly
await db
.insert(table)
.values(values as any)
.returning()
: await db
.insert(table)
.values(values as any)
.returning()
.get();
await db.insert(table).values(values).returning()
: await db.insert(table).values(values).returning().get();
return result;
},
db,