Skip to content

Commit e7e2954

Browse files
waleedlatif1claude
andcommitted
fix(secure-fetch): route early-abort path through settledReject
Promise reject is idempotent so this wasn't a correctness bug, but routing the already-aborted branch through settledReject keeps all settling paths consistent and ensures cleanupAbort runs even if a listener somehow gets registered later. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent 7100fe0 commit e7e2954

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

apps/sim/lib/core/security/input-validation.server.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -416,7 +416,7 @@ export async function secureFetchWithPinnedIP(
416416
if (options.signal) {
417417
if (options.signal.aborted) {
418418
req.destroy()
419-
reject(options.signal.reason ?? new Error('Aborted'))
419+
settledReject(options.signal.reason ?? new Error('Aborted'))
420420
return
421421
}
422422
onAbort = () => {

0 commit comments

Comments
 (0)