Skip to content

Commit feea2e3

Browse files
committed
chore: remove inline comment from advisory lock
1 parent 1fdb0df commit feea2e3

1 file changed

Lines changed: 0 additions & 2 deletions

File tree

  • apps/sim/app/api/workspaces/[id]/environment

apps/sim/app/api/workspaces/[id]/environment/route.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,8 +104,6 @@ export const PUT = withRouteHandler(
104104
).then((entries) => Object.fromEntries(entries))
105105

106106
const { existingEncrypted, merged } = await db.transaction(async (tx) => {
107-
// Advisory lock serialises all writes for this workspaceId, including concurrent
108-
// first-inserts where no row exists yet and FOR UPDATE would acquire nothing.
109107
await tx.execute(sql`SELECT pg_advisory_xact_lock(hashtext(${workspaceId}))`)
110108

111109
const [existingRow] = await tx

0 commit comments

Comments
 (0)