Skip to content

Commit ed6a39e

Browse files
committed
fix: /api/v0/add in Brave
This switches to async iterator version of ipfs.add (introduced to js-ipfs in ipfs/js-ipfs#2517) and ensures Node streams are replaced by deterministic version of readable-stream Closes #757
1 parent 6f3eae5 commit ed6a39e

File tree

3 files changed

+500
-751
lines changed

3 files changed

+500
-751
lines changed

package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -72,11 +72,10 @@
7272
"private": true,
7373
"preferGlobal": false,
7474
"resolutions": {
75-
"libp2p-delegated-content-routing": "0.2.4",
76-
"libp2p-delegated-peer-routing": "0.2.4",
77-
"@hapi/hapi": "https://github.com/lidel/hapi/tarball/0d73f8dde9fc7d518f477b8e04fe5abff1b33777/hapi.tar.gz",
75+
"@hapi/hapi": "18.4.0",
7876
"iso-stream-http": "0.1.2",
7977
"stream-http": "npm:[email protected]",
78+
"stream": "npm:[email protected]",
8079
"pull-to-stream": "0.1.1",
8180
"multiaddr": "6.1.0"
8281
},
@@ -130,7 +129,7 @@
130129
"get-port": "5.0.0",
131130
"http-dns": "3.0.1",
132131
"http-node": "1.2.0",
133-
"ipfs": "https://github.com/ipfs/js-ipfs/tarball/ad65329253da333885b86c7927aa8f0a1e628551/js-ipfs.tar.gz",
132+
"ipfs": "https://github.com/ipfs/js-ipfs/tarball/d9986ee4d7945f6a5d77dc7a2db4863d06971eb9/js-ipfs.tar.gz",
134133
"ipfs-css": "0.13.1",
135134
"ipfs-http-client": "38.2.0",
136135
"ipfs-http-response": "0.3.1",
@@ -150,6 +149,7 @@
150149
"piggybacker": "2.0.0",
151150
"postmsg-rpc": "2.4.0",
152151
"pull-file-reader": "1.0.2",
152+
"readable-stream": "3.4.0",
153153
"tachyons": "4.11.1",
154154
"timers-browserify-full": "0.0.1",
155155
"uri-to-multiaddr": "3.0.1",

webpack.config.js

+1
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ const commonConfig = {
5959
extensions: ['.js', '.json'],
6060
alias: {
6161
url: 'iso-url',
62+
stream: 'readable-stream', // cure general insanity
6263
http: 'http-node', // chrome.sockets
6364
dns: 'http-dns', // chrome.sockets
6465
dgram: 'chrome-dgram', // chrome.sockets

0 commit comments

Comments
 (0)