blind-peer 3.8.0 → 3.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +3 -1
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -213,6 +213,7 @@ class BlindPeer extends ReadyResource {
213
213
  ipBanListKeys = [],
214
214
  banTimeout = 16_000,
215
215
  port,
216
+ bootstrap = null,
216
217
  announcingInterval = 100,
217
218
  wakeupGcTickTime = null,
218
219
  replicationLagThreshold = 100,
@@ -230,6 +231,7 @@ class BlindPeer extends ReadyResource {
230
231
  this.banTimeout = banTimeout
231
232
 
232
233
  this._port = port || 0
234
+ this.bootstrap = bootstrap
233
235
  this.announcingInterval = announcingInterval
234
236
  this.trustedPubKeys = new Set()
235
237
  for (const k of trustedPubKeys || []) this.addTrustedPubKey(k)
@@ -341,7 +343,7 @@ class BlindPeer extends ReadyResource {
341
343
  this.store.watch(this._oncoreopen.bind(this))
342
344
 
343
345
  if (this.swarm === null) {
344
- const swarmOpts = { keyPair: this.db.swarmingKeyPair }
346
+ const swarmOpts = { keyPair: this.db.swarmingKeyPair, bootstrap: this.bootstrap }
345
347
  if (this._port) {
346
348
  swarmOpts.port = typeof this._port === 'number' ? [this._port, this._port + 64] : this._port
347
349
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "blind-peer",
3
- "version": "3.8.0",
3
+ "version": "3.8.1",
4
4
  "description": "Blind peers help keep hypercores available",
5
5
  "main": "index.js",
6
6
  "dependencies": {