diff --git a/gradle.properties b/gradle.properties index 755ca3d..d4aa50d 100644 --- a/gradle.properties +++ b/gradle.properties @@ -9,7 +9,7 @@ yarn_mappings=1.20.1+build.10 loader_version=0.16.5 # Mod Properties -mod_version=1.10.1 +mod_version=1.10.2 maven_group=cc.reconnected archives_base_name=rcc-server diff --git a/src/main/java/cc/reconnected/server/database/PlayerData.java b/src/main/java/cc/reconnected/server/database/PlayerData.java index bdb0b52..201e85f 100644 --- a/src/main/java/cc/reconnected/server/database/PlayerData.java +++ b/src/main/java/cc/reconnected/server/database/PlayerData.java @@ -88,6 +88,12 @@ public class PlayerData { }); } + @SuppressWarnings("UnusedReturnValue") + public CompletableFuture set(String key, @Nullable String value, boolean replace) { + if (replace) delete(key); + return set(key, value); + } + public @Nullable String get(String key) { if (!nodes.containsKey(nodePrefix + "." + key)) return null;