Copy process.env
before lower-casing the keys
`process.env` is read-only in GitBash (and potentially other consoles), so the `lowerCase` flag had no effect.
This commit is contained in:
parent
3d4e589578
commit
392c6022c9
1 changed files with 3 additions and 2 deletions
|
@ -60,8 +60,9 @@ Env.prototype.loadEnv = function () {
|
||||||
var env = process.env;
|
var env = process.env;
|
||||||
|
|
||||||
if (this.lowerCase) {
|
if (this.lowerCase) {
|
||||||
Object.keys(env).forEach(function (key) {
|
env = {};
|
||||||
env[key.toLowerCase()] = env[key];
|
Object.keys(process.env).forEach(function (key) {
|
||||||
|
env[key.toLowerCase()] = process.env[key];
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue