Skip to content

Commit 2282249

Browse files
authored
fix: remove abort controller deps (#162)
`AbortController` and `AbortSignal` are supported in browsers and node 14+ so the extra deps aren't necessary any more.
1 parent 55f5abc commit 2282249

File tree

3 files changed

+2
-6
lines changed

3 files changed

+2
-6
lines changed

package.json

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,7 @@
4848
},
4949
"license": "MIT",
5050
"dependencies": {
51-
"abort-controller": "^3.0.0",
52-
"any-signal": "^2.1.0",
51+
"any-signal": "^3.0.0",
5352
"buffer": "^6.0.1",
5453
"electron-fetch": "^1.7.2",
5554
"err-code": "^3.0.1",
@@ -59,14 +58,13 @@
5958
"it-to-stream": "^1.0.0",
6059
"merge-options": "^3.0.4",
6160
"nanoid": "^3.1.20",
62-
"native-abort-controller": "^1.0.3",
6361
"native-fetch": "^3.0.0",
6462
"node-fetch": "https://registry.npmjs.org/@achingbrain/node-fetch/-/node-fetch-2.6.7.tgz",
6563
"react-native-fetch-api": "^2.0.0",
6664
"stream-to-it": "^0.2.2"
6765
},
6866
"devDependencies": {
69-
"aegir": "^35.0.1",
67+
"aegir": "^36.1.1",
7068
"delay": "^5.0.0",
7169
"events": "^3.3.0",
7270
"ipfs-unixfs": "^6.0.4",

src/http.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ const { fetch, Request, Headers } = require('./http/fetch')
55
const { TimeoutError, HTTPError } = require('./http/error')
66
const merge = require('merge-options').bind({ ignoreUndefined: true })
77
const { URL, URLSearchParams } = require('iso-url')
8-
const { AbortController } = require('native-abort-controller')
98
const anySignal = require('any-signal')
109

1110
/**

test/http.spec.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ const HTTP = require('../src/http')
66
// @ts-ignore
77
const toStream = require('it-to-stream')
88
const delay = require('delay')
9-
const { AbortController } = require('native-abort-controller')
109
const drain = require('it-drain')
1110
const all = require('it-all')
1211
const { isBrowser, isWebWorker, isReactNative } = require('../src/env')

0 commit comments

Comments
 (0)