Skip to content

Commit a8005df

Browse files
committed
Added not-null constraint for settings tables
1 parent f33c961 commit a8005df

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/crdata/stores/settings.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ export const settings = ({ store }: DB) =>
1313
await db.schema
1414
.createTable(collection)
1515
.ifNotExists()
16-
.addColumn("key", "text", (x) => x.primaryKey())
16+
.addColumn("key", "text", (x) => x.primaryKey().notNull())
1717
.addColumn("value", "text")
1818
.execute();
1919
await db.schema
@@ -45,5 +45,5 @@ export const settings = ({ store }: DB) =>
4545
.executeTakeFirstOrThrow()
4646
.then((x) => x.key);
4747
},
48-
}
48+
},
4949
);

0 commit comments

Comments
 (0)