Implement metadata refresh

This commit is contained in:
Zoe Roux
2026-03-27 10:40:22 +01:00
parent 3a2aa61ac1
commit 59187a024b
27 changed files with 2153 additions and 35 deletions
-1
View File
@@ -78,7 +78,6 @@ export const entries = schema.table(
.notNull()
.$onUpdate(() => new Date()),
availableSince: timestamp({ withTimezone: true, precision: 3 }),
nextRefresh: timestamp({ withTimezone: true, precision: 3 }).notNull(),
},
(t) => [
unique().on(t.showPk, t.seasonNumber, t.episodeNumber),
-1
View File
@@ -51,7 +51,6 @@ export const seasons = schema.table(
updatedAt: timestamp({ withTimezone: true, precision: 3 })
.notNull()
.$onUpdate(() => new Date()),
nextRefresh: timestamp({ withTimezone: true, precision: 3 }).notNull(),
},
(t) => [
unique().on(t.showPk, t.seasonNumber),
+1 -1
View File
@@ -93,7 +93,7 @@ export const shows = schema.table(
updatedAt: timestamp({ withTimezone: true, precision: 3 })
.notNull()
.$onUpdate(() => new Date()),
nextRefresh: timestamp({ withTimezone: true, precision: 3 }).notNull(),
nextRefresh: date().notNull(),
},
(t) => [
unique("kind_slug").on(t.kind, t.slug),