From 2ba6e6f9f3328f06986b1dbc5816dca87d66c971 Mon Sep 17 00:00:00 2001 From: often Date: Tue, 16 Jan 2024 18:04:40 +0300 Subject: [PATCH] Fixed TargetYml#getSlot --- .../src/main/kotlin/com/willfp/reforges/config/TargetYml.kt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/eco-core/core-plugin/src/main/kotlin/com/willfp/reforges/config/TargetYml.kt b/eco-core/core-plugin/src/main/kotlin/com/willfp/reforges/config/TargetYml.kt index b33f27b..c1b4ff3 100644 --- a/eco-core/core-plugin/src/main/kotlin/com/willfp/reforges/config/TargetYml.kt +++ b/eco-core/core-plugin/src/main/kotlin/com/willfp/reforges/config/TargetYml.kt @@ -34,12 +34,12 @@ class TargetYml(plugin: EcoPlugin) : StaticBaseConfig("target", plugin, ConfigTy } /** - * Get all materials from a target name. + * Get a [SlotType] for the target. * * @param target The name of the target. - * @return All materials. + * @return The [SlotType]. */ fun getSlot(target: String): SlotType { - return SlotTypes[target] ?: SlotTypeAny + return SlotTypes[this.getString("$target.slot")] ?: SlotTypeAny } }