From 9f1999c01e2ebc1cfed7630c16987f5a0ceedfb0 Mon Sep 17 00:00:00 2001 From: Scott Motte Date: Tue, 13 Feb 2024 09:40:03 -0800 Subject: [PATCH 1/2] add 12 showing issue --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 902f37d5..aca746c8 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -12,7 +12,7 @@ jobs: strategy: matrix: - node-version: [14.x, 16.x, 18.x, 20.x] + node-version: [12.x, 14.x, 16.x, 18.x, 20.x] steps: - uses: actions/checkout@v3 From 1dc22d312fc641c9384fcec4b8181d089e37de8c Mon Sep 17 00:00:00 2001 From: Scott Motte Date: Tue, 13 Feb 2024 09:41:49 -0800 Subject: [PATCH 2/2] replace 14 chaining operator --- lib/main.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/main.js b/lib/main.js index a7b6aeb9..1a99afdf 100644 --- a/lib/main.js +++ b/lib/main.js @@ -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) { if (!Array.isArray(options.path)) { if (fs.existsSync(options.path)) { optionPathsThatExist = [_resolveHome(options.path)]