Skip to content

Commit 8bf7ebe

Browse files
committed
compatibility adjustment
1 parent 961dfa1 commit 8bf7ebe

2 files changed

Lines changed: 3 additions & 4 deletions

File tree

prisma/migrations/20250612150847_init/migration.sql renamed to prisma/migrations/20250612193259_init/migration.sql

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,11 @@ CREATE TABLE `Instance` (
1717
-- CreateTable
1818
CREATE TABLE `Auth` (
1919
`id` INTEGER NOT NULL AUTO_INCREMENT,
20-
`token` VARCHAR(191) NOT NULL,
20+
`token` TEXT NOT NULL,
2121
`createdAt` DATETIME(3) NULL DEFAULT CURRENT_TIMESTAMP(3),
2222
`updatedAt` DATETIME(3) NULL,
2323
`instanceId` INTEGER NOT NULL,
2424

25-
UNIQUE INDEX `Auth_token_key`(`token`),
2625
UNIQUE INDEX `Auth_instanceId_key`(`instanceId`),
2726
PRIMARY KEY (`id`)
2827
) DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;

prisma/schema.prisma

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ model Instance {
6666

6767
model Auth {
6868
id Int @id @default(autoincrement())
69-
token String @unique
69+
token String @db.Text
7070
createdAt DateTime? @default(now())
7171
updatedAt DateTime? @updatedAt
7272
Instance Instance @relation(fields: [instanceId], references: [id], onDelete: Cascade)
@@ -100,7 +100,7 @@ model Message {
100100
device DeviceMessage
101101
isGroup Boolean? @db.TinyInt
102102
Instance Instance @relation(fields: [instanceId], references: [id], onDelete: Cascade)
103-
instanceId Int
103+
instanceId Int @db.Int
104104
MessageUpdate MessageUpdate[]
105105
Media Media?
106106

0 commit comments

Comments
 (0)