From e56fc7c54b29ea3521ac2ffdb4c8cf0646cd99db Mon Sep 17 00:00:00 2001 From: YouHaveTrouble Date: Thu, 26 Mar 2026 19:25:10 +0100 Subject: [PATCH] prevent an exception from happening on boot due to unmodifiable set in the config codec --- pom.xml | 2 +- .../quickerstacker/config/QuickerStackerConfig.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pom.xml b/pom.xml index ba5b073..16309bb 100644 --- a/pom.xml +++ b/pom.xml @@ -21,7 +21,7 @@ 25 UTF-8 2026.03.26-89796e57b - 1.4.1 + 1.4.2 diff --git a/src/main/java/me/youhavetrouble/quickerstacker/config/QuickerStackerConfig.java b/src/main/java/me/youhavetrouble/quickerstacker/config/QuickerStackerConfig.java index 5e8c60c..b11bd10 100644 --- a/src/main/java/me/youhavetrouble/quickerstacker/config/QuickerStackerConfig.java +++ b/src/main/java/me/youhavetrouble/quickerstacker/config/QuickerStackerConfig.java @@ -18,7 +18,7 @@ public class QuickerStackerConfig { .append(new KeyedCodec<>("QuickStackInteractions", Codec.STRING_ARRAY), (config, value) -> { config.quickStackInteractions = value; - config.quickStackInteractionSet = Collections.unmodifiableSet(new HashSet<>(Arrays.asList(config.quickStackInteractions))); + config.quickStackInteractionSet = new HashSet<>(Arrays.asList(config.quickStackInteractions)); }, (config) -> config.quickStackInteractions) .documentation("List of interaction IDs that when detected on a block will cause QuickerStacker to attempt to add its own right click quick stack interaction. This only takes `Use` interaction type.") @@ -28,7 +28,7 @@ public class QuickerStackerConfig { public QuickerStackerConfig() {} public Set getQuickStackContainers() { - return quickStackInteractionSet; + return Collections.unmodifiableSet(quickStackInteractionSet); } }