From 4b16f1262323c0869a093244686cf5d3e1edd4d7 Mon Sep 17 00:00:00 2001 From: ChomeNS <95471003+ChomeNS@users.noreply.github.com> Date: Mon, 4 Nov 2024 19:06:43 +0700 Subject: [PATCH] fix: mabe --- .../me/chayapak1/chomens_bot/util/FileLoggerUtilities.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/me/chayapak1/chomens_bot/util/FileLoggerUtilities.java b/src/main/java/me/chayapak1/chomens_bot/util/FileLoggerUtilities.java index 97bd5b4..1c06953 100644 --- a/src/main/java/me/chayapak1/chomens_bot/util/FileLoggerUtilities.java +++ b/src/main/java/me/chayapak1/chomens_bot/util/FileLoggerUtilities.java @@ -84,14 +84,14 @@ public class FileLoggerUtilities { if (!Files.exists(logPath)) Files.createFile(logPath); - logWriter = Files.newBufferedWriter(logPath, StandardCharsets.UTF_8, StandardOpenOption.TRUNCATE_EXISTING); + logWriter = Files.newBufferedWriter(logPath, StandardCharsets.UTF_16, StandardOpenOption.TRUNCATE_EXISTING); logWriter.write(currentLogDate.toString() + '\n'); logWriter.flush(); } public static void openLogFile() throws IOException { currentLogDate = LocalDate.parse(getLogDate(logPath)); - logWriter = Files.newBufferedWriter(logPath, StandardCharsets.UTF_8, StandardOpenOption.APPEND); + logWriter = Files.newBufferedWriter(logPath, StandardCharsets.UTF_16, StandardOpenOption.APPEND); } public static void compressLogFile() throws IOException {