File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed
Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ export const StubRequest = /* @__PURE__ */ (() => {
22 class StubRequest implements Omit < Request , "fetcher" | "cf" > {
33 url : string ;
44
5- _signal ?: AbortSignal ;
5+ _abortController ?: AbortController ;
66 _headers ?: Headers ;
77 _init ?: RequestInit ;
88
@@ -29,7 +29,10 @@ export const StubRequest = /* @__PURE__ */ (() => {
2929 }
3030
3131 get signal ( ) {
32- return ( this . _signal ??= new AbortController ( ) . signal ) ;
32+ if ( ! this . _abortController ) {
33+ this . _abortController = new AbortController ( ) ;
34+ }
35+ return this . _abortController . signal ;
3336 }
3437
3538 get cache ( ) {
@@ -69,7 +72,7 @@ export const StubRequest = /* @__PURE__ */ (() => {
6972 }
7073
7174 get body ( ) {
72- return null ; // eslint-disable-line unicorn/no-null
75+ return null ;
7376 }
7477
7578 get bodyUsed ( ) {
You can’t perform that action at this time.
0 commit comments