mirror of
https://github.com/stack-auth/stack.git
synced 2026-06-13 21:01:21 +08:00
Fix STACK-BACKEND-2J
This commit is contained in:
parent
6272cdf8dc
commit
0f55c18e98
@ -28,7 +28,7 @@ export async function retryTransaction<T>(fn: (...args: Parameters<Parameters<ty
|
||||
try {
|
||||
return Result.ok(await prismaClient.$transaction(fn));
|
||||
} catch (e) {
|
||||
if (e instanceof Prisma.PrismaClientKnownRequestError) {
|
||||
if (e instanceof Prisma.PrismaClientKnownRequestError || e instanceof Prisma.PrismaClientUnknownRequestError) {
|
||||
// retry
|
||||
return Result.error(e);
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user