diff options
author | J10a1n15 <45315647+j10a1n15@users.noreply.github.com> | 2024-06-22 08:42:49 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-22 08:42:49 +0200 |
commit | 4c1f34ff39c9ab59991648cc1a7c771ef7b1d8a2 (patch) | |
tree | aabb44055ea8bd8f4e5192c810901e1f17b261a5 | |
parent | d534f73b63578d384c7a69462ca18cf0883926f5 (diff) | |
download | skyhanni-4c1f34ff39c9ab59991648cc1a7c771ef7b1d8a2.tar.gz skyhanni-4c1f34ff39c9ab59991648cc1a7c771ef7b1d8a2.tar.bz2 skyhanni-4c1f34ff39c9ab59991648cc1a7c771ef7b1d8a2.zip |
Fix: Custom Wardrobe Price Error (#2123)
Co-authored-by: Empa <42304516+ItsEmpa@users.noreply.github.com>
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/features/inventory/wardrobe/WardrobeAPI.kt | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/inventory/wardrobe/WardrobeAPI.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/wardrobe/WardrobeAPI.kt index f57761102..c977bb031 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/inventory/wardrobe/WardrobeAPI.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/wardrobe/WardrobeAPI.kt @@ -9,6 +9,7 @@ import at.hannibal2.skyhanni.features.misc.items.EstimatedItemValueCalculator import at.hannibal2.skyhanni.skyhannimodule.SkyHanniModule import at.hannibal2.skyhanni.utils.DelayedRun import at.hannibal2.skyhanni.utils.InventoryUtils +import at.hannibal2.skyhanni.utils.ItemUtils.getInternalNameOrNull import at.hannibal2.skyhanni.utils.ItemUtils.name import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.NumberUtil.formatInt @@ -94,7 +95,7 @@ object WardrobeAPI { if (slot.isEmpty()) return@buildList add("§aEstimated Armor Value:") var totalPrice = 0.0 - for (stack in slot.armor.filterNotNull()) { + for (stack in slot.armor.filterNotNull().filter { it.getInternalNameOrNull() != null }) { val price = EstimatedItemValueCalculator.getTotalPrice(stack) add(" §7- ${stack.name}: §6${price.shortFormat()}") totalPrice += price |