From 750f5838d53340f56146d9f6b84b38fbc67f6e41 Mon Sep 17 00:00:00 2001 From: rockingrohit9639 Date: Tue, 8 Oct 2024 10:33:03 +0530 Subject: [PATCH] fix: transaction issue on bulk delete assets --- app/modules/asset/service.server.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/app/modules/asset/service.server.ts b/app/modules/asset/service.server.ts index 9ce21e71e..49868f759 100644 --- a/app/modules/asset/service.server.ts +++ b/app/modules/asset/service.server.ts @@ -2301,10 +2301,8 @@ export async function bulkDeleteAssets({ }); try { - await db.$transaction(async (tx) => { - await tx.asset.deleteMany({ - where: { id: { in: assets.map((asset) => asset.id) } }, - }); + await db.asset.deleteMany({ + where: { id: { in: assets.map((asset) => asset.id) } }, }); /** Deleting images of the assets (if any) */