Changes sessions to be stored in the DB, this ensures that sessions persist after a restart!
This commit is contained in:
parent
83d93aefc0
commit
1f9bb34853
5 changed files with 103 additions and 30 deletions
|
@ -121,3 +121,11 @@ model ChatMessage {
|
|||
createdAt DateTime @default(now()) @map("created_at")
|
||||
thread ChatThread @relation(fields: [threadId], references: [id], onDelete: Cascade)
|
||||
}
|
||||
|
||||
// Add this model for session storage
|
||||
model Session {
|
||||
id String @id
|
||||
sid String @unique
|
||||
data String
|
||||
expiresAt DateTime @map("expires_at")
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue