Commit f6637c04fbd36d88883b300e1eab12c7be8cb309
remove some dead code
Matt McKegg committed on 11/3/2016, 3:11:07 PMParent: f703d4b697a84bf5b0753fbd2bad791fbc1f28e8
Files changed
plugins/gossip/index.js | changed |
plugins/gossip/schedule.js | changed |
plugins/gossip/index.js | ||
---|---|---|
@@ -1,16 +1,14 @@ | ||
1 | 1 … | |
2 | 2 … | var pull = require('pull-stream') |
3 | 3 … | var Notify = require('pull-notify') |
4 | -var toAddress = require('../../lib/util').toAddress | |
5 | 4 … | var mdm = require('mdmanifest') |
6 | 5 … | var valid = require('../../lib/validators') |
7 | 6 … | var apidoc = require('../../lib/apidocs').gossip |
8 | 7 … | var u = require('../../lib/util') |
9 | 8 … | var ref = require('ssb-ref') |
10 | 9 … | var ping = require('pull-ping') |
11 | 10 … | var stats = require('statistics') |
12 | -var isArray = Array.isArray | |
13 | 11 … | var Schedule = require('./schedule') |
14 | 12 … | var Init = require('./init') |
15 | 13 … | var AtomicFile = require('atomic-file') |
16 | 14 … | var path = require('path') |
@@ -261,10 +259,4 @@ | ||
261 | 259 … | |
262 | 260 … | return gossip |
263 | 261 … | } |
264 | 262 … | } |
265 | - | |
266 | - | |
267 | - | |
268 | - | |
269 | - | |
270 | - |
plugins/gossip/schedule.js | ||
---|---|---|
@@ -1,17 +1,11 @@ | ||
1 | -var nonPrivate = require('non-private-ip') | |
2 | 1 … | var ip = require('ip') |
3 | 2 … | var onWakeup = require('on-wakeup') |
4 | 3 … | var onNetwork = require('on-change-network') |
5 | 4 … | var hasNetwork = require('has-network') |
6 | 5 … | |
7 | 6 … | var pull = require('pull-stream') |
8 | -var u = require('../../lib/util') | |
9 | 7 … | |
10 | -function rand(array) { | |
11 | - return array[~~(Math.random()*array.length)] | |
12 | -} | |
13 | - | |
14 | 8 … | function not (fn) { |
15 | 9 … | return function (e) { return !fn(e) } |
16 | 10 … | } |
17 | 11 … | |
@@ -99,9 +93,9 @@ | ||
99 | 93 … | }), count) |
100 | 94 … | } |
101 | 95 … | |
102 | 96 … | var schedule = exports = module.exports = |
103 | -function (gossip, config, server) { | |
97 … | +function (gossip, config, server) { | |
104 | 98 … | // return |
105 | 99 … | var min = 60e3, hour = 60*60e3 |
106 | 100 … | |
107 | 101 … | //trigger hard reconnect after suspend or local network changes |
Built with git-ssb-web