From 265876786c9e6fec07daadde71a06f032ed7930d Mon Sep 17 00:00:00 2001 From: Pavel Djundik Date: Sun, 22 Jul 2018 00:39:22 +0300 Subject: [PATCH] Don't put .log in text log folder name --- src/plugins/messageStorage/text.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/plugins/messageStorage/text.js b/src/plugins/messageStorage/text.js index 212ad752..97558e79 100644 --- a/src/plugins/messageStorage/text.js +++ b/src/plugins/messageStorage/text.js @@ -97,7 +97,7 @@ class TextFileMessageStorage { line += "\n"; - fs.appendFile(path.join(logPath, cleanFilename(channel.name)), line, (e) => { + fs.appendFile(path.join(logPath, `${cleanFilename(channel.name)}.log`), line, (e) => { if (e) { log.error("Failed to write user log", e); } @@ -122,5 +122,5 @@ function cleanFilename(name) { name = filenamify(name, {replacement: "_"}); name = name.toLowerCase(); - return `${name}.log`; + return name; }