From 8a6a0d5510d510a2a4a3863d0bbb2ab63ff6bd25 Mon Sep 17 00:00:00 2001 From: ChrisChrome Date: Mon, 22 Jul 2024 16:41:57 -0600 Subject: [PATCH] Remove debounce (didnt need it) --- index.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/index.js b/index.js index 0bfcf6e..e084fd1 100644 --- a/index.js +++ b/index.js @@ -295,12 +295,11 @@ fs.readdirSync(process.env.CONFIG_PATH).forEach(file => { break; } }) -var check; + const watchFiles = () => { fs.watch(process.env.CONFIG_PATH, (event, file) => { - clearTimeout(check); // Debounce if (file.startsWith(".")) return; // Ignore hidden files - check = setTimeout(() => { + setTimeout(() => { tmp = {} newContents = fs.readFileSync(path.join(process.env.CONFIG_PATH, file)).toString() switch (file) {