pinokiod 3.293.0 → 3.295.0

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/kernel/peer.js +5 -11
  2. package/package.json +1 -1
package/kernel/peer.js CHANGED
@@ -50,7 +50,11 @@ class PeerDiscovery {
50
50
  }
51
51
  }
52
52
  async check(kernel) {
53
- const env = await Environment.get(kernel.homedir, kernel)
53
+ let env
54
+ try {
55
+ env = await Environment.get(kernel.homedir, kernel)
56
+ } catch (e) {
57
+ }
54
58
  const resolveFlag = (key, fallback) => {
55
59
  const fromEnvFile = env && typeof env[key] !== 'undefined' ? String(env[key]) : undefined
56
60
  const fromProcess = typeof process.env[key] !== 'undefined' ? String(process.env[key]) : undefined
@@ -93,17 +97,7 @@ class PeerDiscovery {
93
97
  }
94
98
  }
95
99
  async start(kernel) {
96
- let env = await Environment.get(kernel.homedir, kernel)
97
-
98
- // by default expose to the local network
99
- //this.active = true
100
- // if PINOKIO_NETWORK_SHARE is 0 or false, turn it off
101
- // if (env && env.PINOKIO_NETWORK_ACTIVE && (env.PINOKIO_NETWORK_ACTIVE==="0" || env.PINOKIO_NETWORK_ACTIVE.toLowerCase()==="false")) {
102
100
  await this.check(kernel)
103
- // if (env && env.PINOKIO_NETWORK_ACTIVE && (env.PINOKIO_NETWORK_ACTIVE==="1" || env.PINOKIO_NETWORK_ACTIVE.toLowerCase()==="true")) {
104
- //// this.active = false
105
- // this.active = true
106
- // }
107
101
 
108
102
  //if (this.active) {
109
103
  if (this.peer_active) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pinokiod",
3
- "version": "3.293.0",
3
+ "version": "3.295.0",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {