From 8f7311289b3a99d8fecb46f396cf1e46d398c7f0 Mon Sep 17 00:00:00 2001 From: anthonyshibitov Date: Sat, 13 May 2023 20:00:37 -0400 Subject: [PATCH] Add debug message if no encoding is specified If no encoding is specified in the options, debug will alert the user that UTF-8 will be used as the default. Closes #657 --- lib/main.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/main.js b/lib/main.js index ce7ca50e..1247a430 100644 --- a/lib/main.js +++ b/lib/main.js @@ -199,6 +199,10 @@ function _configDotenv (options) { } if (options.encoding != null) { encoding = options.encoding + } else { + if (debug) { + _debug('No encoding is specified. UTF-8 is used by default') + } } }