From 956d4fa10c154e1efdd78a103df45eed2b2a2229 Mon Sep 17 00:00:00 2001 From: Auxilor Date: Wed, 24 Jul 2024 15:24:19 +0100 Subject: [PATCH] Enchantment arg parser is now case insensitive --- .../com/willfp/eco/internal/items/ArgParserEnchantment.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eco-core/core-backend/src/main/kotlin/com/willfp/eco/internal/items/ArgParserEnchantment.kt b/eco-core/core-backend/src/main/kotlin/com/willfp/eco/internal/items/ArgParserEnchantment.kt index c16aa0d7..750c6ebf 100644 --- a/eco-core/core-backend/src/main/kotlin/com/willfp/eco/internal/items/ArgParserEnchantment.kt +++ b/eco-core/core-backend/src/main/kotlin/com/willfp/eco/internal/items/ArgParserEnchantment.kt @@ -16,7 +16,7 @@ object ArgParserEnchantment : LookupArgParser { for (arg in args) { val argSplit = arg.split(":") - val enchant = Enchantment.getByKey(NamespacedKey.minecraft(argSplit[0])) ?: continue + val enchant = Enchantment.getByKey(NamespacedKey.minecraft(argSplit[0].lowercase())) ?: continue val level = argSplit.getOrNull(1)?.toIntOrNull() ?: enchant.maxLevel enchants[enchant] = level