All checks were successful
CI / ci (push) Successful in 15s
Run biome check --write --unsafe to fix tabs, import ordering, and non-null assertions across entire codebase. Disable a11y rules not applicable to this single-user app. Exclude auto-generated routeTree. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
15 lines
300 B
TypeScript
15 lines
300 B
TypeScript
import { db } from "./index.ts";
|
|
import { categories } from "./schema.ts";
|
|
|
|
export function seedDefaults() {
|
|
const existing = db.select().from(categories).all();
|
|
if (existing.length === 0) {
|
|
db.insert(categories)
|
|
.values({
|
|
name: "Uncategorized",
|
|
icon: "package",
|
|
})
|
|
.run();
|
|
}
|
|
}
|