@hyperswarm/rpc
Advanced tools
Comparing version 2.0.0 to 2.0.1
@@ -13,8 +13,9 @@ const EventEmitter = require('events') | ||
debug, | ||
dht = new DHT({ keyPair, bootstrap, debug }) | ||
dht | ||
} = options | ||
this._dht = dht | ||
this._dht = dht || new DHT({ keyPair, bootstrap, debug }) | ||
this._defaultKeyPair = keyPair | ||
this._defaultValueEncoding = valueEncoding | ||
this._autoDestroy = !dht | ||
@@ -71,2 +72,4 @@ this._clients = new Set() | ||
} | ||
if (this._autoDestroy) await this._dht.destroy() | ||
} | ||
@@ -73,0 +76,0 @@ } |
{ | ||
"name": "@hyperswarm/rpc", | ||
"version": "2.0.0", | ||
"version": "2.0.1", | ||
"description": "RPC over the Hyperswarm DHT", | ||
@@ -27,3 +27,3 @@ "main": "index.js", | ||
"devDependencies": { | ||
"@hyperswarm/testnet": "^1.1.0", | ||
"@hyperswarm/testnet": "^2.0.0", | ||
"brittle": "^2.3.1", | ||
@@ -30,0 +30,0 @@ "compact-encoding": "^2.6.1", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
10640
176