Skip to content
This repository was archived by the owner on Feb 12, 2024. It is now read-only.

Commit f72e5ef

Browse files
committed
fix: last touches for dns websockets bootstrapers
1 parent 2cb3178 commit f72e5ef

File tree

3 files changed

+12
-5
lines changed

3 files changed

+12
-5
lines changed

examples/transfer-files/public/js/app.js

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ function onDrop (event) {
156156
.join('<br>')
157157
})
158158
.catch(onError)
159-
}
159+
})
160160
}
161161

162162
/*
@@ -187,7 +187,14 @@ function refreshPeerList () {
187187
}
188188

189189
const peersAsHtml = peers
190-
.map((peer) => peer.addr.toString())
190+
.map((peer) => {
191+
const addr = peer.addr.toString()
192+
if (addr.indexOf('ipfs') >= 0) {
193+
return addr
194+
} else {
195+
return addr + peer.peer.id.toB58String()
196+
}
197+
})
191198
.map((addr) => {
192199
return '<li>' + addr + '</li>'
193200
}).join('')

src/init-files/default-config-node.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,6 @@
2525
"/ip4/104.236.76.40/tcp/4001/ipfs/QmSoLV4Bbm51jM9C4gDYZQ9Cy3U6aXMJDAbzgu2fzaDs64",
2626
"/ip4/178.62.158.247/tcp/4001/ipfs/QmSoLer265NRgSp2LA3dPaeykiS1J6DifTC88f5uVQKNAd",
2727
"/ip4/178.62.61.185/tcp/4001/ipfs/QmSoLMeWqB7YGVLJN3pNLQpmmEk35v6wYtsMGLzSr5QBU3",
28-
"/ip4/104.236.151.122/tcp/4001/ipfs/QmSoLju6m7xTh3DuokvT3886QRYqxAzb1kShaanJgW36yx",
29-
"/dns4/strawberry.i.ipfs.io/wss/ipfs/QmWyLSnMHW2H6bmCG9e9PQq4ARve94JduvGjbutUuzx4a8",
30-
"/dns4/blueberry.i.ipfs.io/wss/ipfs/QmVcj9MATxGTAFoQSbrJvZ9Fbs4Jzvrxy9hyJeRwbW8NeA"
28+
"/ip4/104.236.151.122/tcp/4001/ipfs/QmSoLju6m7xTh3DuokvT3886QRYqxAzb1kShaanJgW36yx"
3129
]
3230
}

test/http-api/spec/bootstrap.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,8 @@ module.exports = (http) => {
2727
url: '/api/v0/bootstrap/list'
2828
}, (res) => {
2929
expect(res.statusCode).to.be.eql(200)
30+
console.log(res.result.Peers)
31+
console.log(defaultList)
3032
expect(res.result.Peers).to.deep.equal(defaultList)
3133
done()
3234
})

0 commit comments

Comments
 (0)