Skip to content

Commit 1b5857f

Browse files
Update packages/svelte/src/internal/server/abort-signal.js
Co-authored-by: Elliott Johnson <[email protected]>
1 parent 61c0eaa commit 1b5857f

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

packages/svelte/src/internal/server/abort-signal.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,8 @@ import { STALE_REACTION } from '#client/constants';
44
export let controller = null;
55

66
export function abort() {
7-
if (controller !== null) {
8-
controller.abort(STALE_REACTION);
9-
controller = null;
10-
}
7+
controller?.abort(STALE_REACTION);
8+
controller = null;
119
}
1210

1311
export function getAbortSignal() {

0 commit comments

Comments
 (0)