@env-ctrl/node 0.2.0 → 0.2.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@env-ctrl/node",
3
- "version": "0.2.0",
3
+ "version": "0.2.1",
4
4
  "description": "Load environment variables from env-ctrl (envctrl.com) into process.env at startup: one token instead of a .env file.",
5
5
  "homepage": "https://envctrl.com",
6
6
  "keywords": [
@@ -19,5 +19,5 @@ try {
19
19
  out({ values: await res.json(), missing: list('x-envctrl-missing'), invalid: list('x-envctrl-invalid') });
20
20
  }
21
21
  } catch (e) {
22
- out({ error: `cannot reach ${url} (${e.cause?.code ?? e.name ?? e.message})` });
22
+ out({ error: `cannot reach ${url} (${e.cause?.code ?? e.cause?.errors?.[0]?.code ?? (e.name === 'TimeoutError' ? 'timeout' : e.message)})` });
23
23
  }