mirror of
https://github.com/CherryHQ/cherry-studio.git
synced 2026-01-07 13:59:28 +08:00
refactor(db): convert table index definitions from object to array syntax
The change improves consistency with the library's preferred style and makes the code more maintainable
This commit is contained in:
parent
ffc3b43dc5
commit
d4df86e6bc
@ -19,10 +19,10 @@ export const videoTable = sqliteTable(
|
|||||||
error: text('error', { mode: 'json' }),
|
error: text('error', { mode: 'json' }),
|
||||||
...createUpdateTimestamps
|
...createUpdateTimestamps
|
||||||
},
|
},
|
||||||
(table) => ({
|
(table) => [
|
||||||
statusIdx: index('status_idx').on(table.status),
|
index('status_idx').on(table.status),
|
||||||
providerIdx: index('provider_idx').on(table.providerId),
|
index('provider_idx').on(table.providerId),
|
||||||
typeIdx: index('type_idx').on(table.type),
|
index('type_idx').on(table.type),
|
||||||
fileIdIdx: uniqueIndex('file_id_idx').on(table.fileId)
|
uniqueIndex('file_id_idx').on(table.fileId)
|
||||||
})
|
]
|
||||||
)
|
)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user