microframework
Advanced tools
Comparing version 0.0.7 to 0.0.8
@@ -85,2 +85,3 @@ declare module 'microframework/MicroFrameworkConfig' { | ||
private loadParameters(); | ||
private requireFile(file); | ||
private requireEnvironmentFile(file); | ||
@@ -87,0 +88,0 @@ } |
@@ -172,4 +172,8 @@ "use strict"; | ||
var configFiles = this.getConfigFiles(); | ||
configFiles.forEach(function (file) { | ||
return _tConfiguratorConfigurator.defaultConfigurator.addConfiguration(require(file)); | ||
configFiles.map(function (file) { | ||
return _this2.requireFile(file); | ||
}).filter(function (file) { | ||
return !!file; | ||
}).forEach(function (file) { | ||
return _tConfiguratorConfigurator.defaultConfigurator.addConfiguration(file); | ||
}); | ||
@@ -196,4 +200,6 @@ configFiles.map(function (file) { | ||
var parametersFiles = this.getParameterFiles(); | ||
parametersFiles.map(function (fileName) { | ||
return require(fileName); | ||
parametersFiles.map(function (file) { | ||
return _this3.requireFile(file); | ||
}).filter(function (file) { | ||
return !!file; | ||
}).forEach(function (file) { | ||
@@ -212,2 +218,11 @@ return merge(file, parameters); | ||
}, { | ||
key: "requireFile", | ||
value: function requireFile(file) { | ||
try { | ||
fs.statSync(file); | ||
return require(file); | ||
} catch (e) {} | ||
return undefined; | ||
} | ||
}, { | ||
key: "requireEnvironmentFile", | ||
@@ -214,0 +229,0 @@ value: function requireEnvironmentFile(file) { |
{ | ||
"name": "microframework", | ||
"version": "0.0.7", | ||
"version": "0.0.8", | ||
"description": "Micro framework is a bundle of express.js, mongodb ODM, validator, dependancy injection framework and restful controllers for your apps using Typescript", | ||
@@ -35,3 +35,3 @@ "license": "Apache-2.0", | ||
"path": "^0.12.7", | ||
"t-configurator": "^0.0.4", | ||
"t-configurator": "^0.0.5", | ||
"t-validator": "^0.0.2", | ||
@@ -38,0 +38,0 @@ "type-controllers": "^0.0.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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
20499
344
4
0
+ Addedt-configurator@0.0.5(transitive)
- Removedt-configurator@0.0.4(transitive)
Updatedt-configurator@^0.0.5