config 4.0.1 → 4.1.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.
package/lib/config.js CHANGED
@@ -505,13 +505,9 @@ util.loadFileConfigs = function(configDir, options) {
505
505
  let opts = {...FIRST_LOAD.options, configDir, ...options};
506
506
  newLoad = new Load(opts);
507
507
  newLoad.scan();
508
-
509
- FIRST_LOAD.sourcesBug(newLoad.getSources());
510
508
  } else {
511
509
  newLoad = new Load({...FIRST_LOAD.options, ...options});
512
510
  _init(newLoad);
513
-
514
- FIRST_LOAD.sourcesBug(newLoad.getSources());
515
511
  }
516
512
 
517
513
  return newLoad.config;
@@ -619,10 +615,6 @@ util.parseFile = function(fullFilename, options = {}) {
619
615
 
620
616
  loadInfo.loadFile(fullFilename);
621
617
 
622
- if (!options.skipConfigSources) {
623
- FIRST_LOAD.sourcesBug(loadInfo.getSources());
624
- }
625
-
626
618
  return loadInfo.config;
627
619
  }
628
620
 
package/lib/util.js CHANGED
@@ -977,23 +977,6 @@ class Load {
977
977
  return (this.sources ?? []).slice();
978
978
  }
979
979
 
980
- /**
981
- * Bug-preserving function
982
- *
983
- * This function conserves a bug in loadFileConfigs that makes additional loadFileConfigs
984
- * calls show up as configSources on the singleton, which is incorrect and reduces the
985
- * diagnostic value of inspecting the configSources after a program initialization.
986
- *
987
- * This needs to go but at present there is no other way to surface these values. So this
988
- * function exists until a side-effect-free loadFileConfigs() can be created at the end
989
- * of this rearchitecting work.
990
- *
991
- * @param sources
992
- */
993
- sourcesBug(sources) {
994
- this.sources && this.sources.push(...sources);
995
- }
996
-
997
980
  /**
998
981
  * <p>
999
982
  * Set default configurations for a node.js module.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "config",
3
- "version": "4.0.1",
3
+ "version": "4.1.0",
4
4
  "main": "./lib/config.js",
5
5
  "description": "Configuration control for production node deployments",
6
6
  "author": "Loren West <open_source@lorenwest.com>",
@@ -26,11 +26,11 @@
26
26
  },
27
27
  "devDependencies": {
28
28
  "@types/node": "^7.0.8",
29
+ "c8": "^10.1.3",
29
30
  "coffeescript": "2.2.4",
30
31
  "cson": "^3.0.1",
31
32
  "hjson": "^1.2.0",
32
33
  "js-yaml": "^3.2.2",
33
- "nyc": "^15.1.0",
34
34
  "properties": "~1.2.1",
35
35
  "request": "^2.88.2",
36
36
  "semver": "5.3.0",
@@ -48,19 +48,16 @@
48
48
  "engines": {
49
49
  "node": ">= 20.0.0"
50
50
  },
51
- "nyc": {
51
+ "c8": {
52
52
  "include": [
53
53
  "*.js",
54
54
  "lib/**/*.js"
55
55
  ],
56
- "extension": [
57
- ".js"
58
- ],
59
56
  "report-dir": "./coverage",
60
57
  "reporter": "lcov"
61
58
  },
62
59
  "scripts": {
63
- "test": "nyc vows test/*.js --spec",
64
- "vows": "nyc vows"
60
+ "test": "c8 vows test/*.js --spec",
61
+ "vows": "c8 vows"
65
62
  }
66
63
  }