-
-
Notifications
You must be signed in to change notification settings - Fork 849
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #812 from motdotla/patch-12
patch issue with node 12
- Loading branch information
Showing
2 changed files
with
3 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -207,7 +207,7 @@ function configDotenv (options) { | |
let encoding = 'utf8' | ||
const debug = Boolean(options && options.debug) | ||
|
||
if (options?.encoding) { | ||
if (options && options.encoding) { | ||
encoding = options.encoding | ||
} else { | ||
if (debug) { | ||
|
@@ -216,7 +216,7 @@ function configDotenv (options) { | |
} | ||
|
||
let optionPathsThatExist = [] | ||
if (options?.path) { | ||
if (options && options.path) { | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
motdotla
Author
Owner
|
||
if (!Array.isArray(options.path)) { | ||
if (fs.existsSync(options.path)) { | ||
optionPathsThatExist = [_resolveHome(options.path)] | ||
|
I not sure, but here the browser doesn't like this conditional syntax