feat: add index for snapshots (#8163)

This commit is contained in:
darkskygit
2024-09-08 13:49:40 +00:00
parent 57083905ff
commit 2a135d8a93
5 changed files with 31 additions and 15 deletions

View File

@@ -79,7 +79,7 @@ test('should have sequential update number', async t => {
// fake the seq num is about to overflow
await db.snapshot.update({
where: {
id_workspaceId: {
workspaceId_id: {
id: '2',
workspaceId: '2',
},
@@ -273,7 +273,7 @@ test('should not update snapshot if doc is outdated', async t => {
// fake the snapshot is a lot newer
await db.snapshot.update({
where: {
id_workspaceId: {
workspaceId_id: {
workspaceId: '2',
id: '1',
},