diff --git a/src/main/java/land/chipmunk/chayapak/chomens_bot/util/PersistentDataUtilities.java b/src/main/java/land/chipmunk/chayapak/chomens_bot/util/PersistentDataUtilities.java index 009a547..44514f9 100644 --- a/src/main/java/land/chipmunk/chayapak/chomens_bot/util/PersistentDataUtilities.java +++ b/src/main/java/land/chipmunk/chayapak/chomens_bot/util/PersistentDataUtilities.java @@ -12,22 +12,19 @@ import java.io.IOException; import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.StandardOpenOption; -import java.util.LinkedHashMap; import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ScheduledFuture; import java.util.concurrent.TimeUnit; -import java.util.stream.Stream; public class PersistentDataUtilities { public static final Path path = Path.of("persistent.json"); - public static Stream file; - private static BufferedWriter writer; public static JsonObject jsonObject = new JsonObject(); - private static final Map queue = new LinkedHashMap<>(); + private static final Map queue = new ConcurrentHashMap<>(); private static final ScheduledFuture future;