From 058c39ab0d735de9c9220dbb92251b469eae9605 Mon Sep 17 00:00:00 2001 From: Dorian Niemiec Date: Thu, 29 Aug 2024 19:15:37 +0200 Subject: [PATCH] Replace __dirname with process.dirname --- src/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/index.js b/src/index.js index 7d0e436..ac399c1 100644 --- a/src/index.js +++ b/src/index.js @@ -1674,7 +1674,7 @@ function saveConfig() { if (configJSONobj.optOutOfStatisticsServer === undefined) configJSONobj.optOutOfStatisticsServer = false; - fs.writeFileSync(__dirname + "/config.json", JSON.stringify(configJSONobj, null, 2) + "\n"); + fs.writeFileSync(process.dirname + "/config.json", JSON.stringify(configJSONobj, null, 2) + "\n"); break; } catch (err) { if (i >= 2) throw err;