From 03bb2d2763dae2cef04767c90df965d2860133cd Mon Sep 17 00:00:00 2001 From: Vikhyath Mondreti Date: Thu, 22 Jan 2026 18:08:55 -0800 Subject: [PATCH] delete needs to account for namespace --- apps/sim/lib/core/idempotency/service.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/apps/sim/lib/core/idempotency/service.ts b/apps/sim/lib/core/idempotency/service.ts index aa2bcbe96..e0c84002b 100644 --- a/apps/sim/lib/core/idempotency/service.ts +++ b/apps/sim/lib/core/idempotency/service.ts @@ -148,7 +148,12 @@ export class IdempotencyService { await db .delete(idempotencyKey) - .where(eq(idempotencyKey.key, normalizedKey)) + .where( + and( + eq(idempotencyKey.key, normalizedKey), + eq(idempotencyKey.namespace, this.config.namespace) + ) + ) .catch((err) => logger.warn(`Failed to clean up expired key ${normalizedKey}:`, err)) }