Browse Source

Fix: undici retry on `UND_ERR_DESTROYED`

SukkaW 1 day ago
parent
commit
f77f6bdcc3
1 changed files with 1 additions and 0 deletions
  1. 1 0
      Build/lib/fetch-retry.ts

+ 1 - 0
Build/lib/fetch-retry.ts

@@ -57,6 +57,7 @@ const agent = new Agent({
       // Any code that is not a Undici's originated and allowed to retry
       // Any code that is not a Undici's originated and allowed to retry
       if (
       if (
         errorCode === 'ERR_UNESCAPED_CHARACTERS'
         errorCode === 'ERR_UNESCAPED_CHARACTERS'
+        || errorCode === 'UND_ERR_DESTROYED'
         || err.message === 'Request path contains unescaped characters'
         || err.message === 'Request path contains unescaped characters'
         || err.name === 'AbortError'
         || err.name === 'AbortError'
       ) {
       ) {