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

Commit ea70e0b

Browse files
code review fixes
1 parent e804947 commit ea70e0b

File tree

3 files changed

+3
-14
lines changed

3 files changed

+3
-14
lines changed

src/cli/commands/bitswap/unwant.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ module.exports = Command.extend({
1818
throw err
1919
}
2020

21-
// TODO: implement
21+
throw new Error('Not implemented yet')
2222
})
2323
}
2424
})

src/core/ipfs/go-offline.js

+1-9
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,9 @@
11
'use strict'
22

3-
const debug = require('debug')
4-
const log = debug('core:offline')
5-
63
module.exports = function goOffline (self) {
74
return (cb) => {
85
self._blockS.goOffline()
96
self._bitswap.stop()
10-
self.libp2p.stop((err) => {
11-
if (err) {
12-
log('Error trying to go offline', err)
13-
}
14-
cb()
15-
})
7+
self.libp2p.stop(cb)
168
}
179
}

src/http-api/resources/bitswap.js

+1-4
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,6 @@ exports.unwant = {
4141
parseArgs: parseKey,
4242

4343
handler: (request, reply) => {
44-
const key = request.pre.args.key
45-
46-
request.server.app.ipfs.bitswap.unwant(key)
47-
reply()
44+
reply(boom.badRequrest(new Error('Not implemented yet')))
4845
}
4946
}

0 commit comments

Comments
 (0)