9
0
mirror of https://github.com/HibiscusMC/HMCCosmetics.git synced 2025-12-30 12:29:16 +00:00

fix: equipped cosmetic placeholder returning untranslated string when no cosmetics is in slot

This commit is contained in:
LoJoSho
2023-08-08 20:31:33 -05:00
parent 2aed727832
commit 20da7797c9

View File

@@ -152,7 +152,7 @@ public class HMCPlaceholderExpansion extends PlaceholderExpansion {
return "INVALID_COSMETIC";
}
}
if (user.getCosmetic(cosmetic.getSlot()) == null) return "false";
if (user.getCosmetic(cosmetic.getSlot()) == null) TranslationUtil.getTranslation("equipped-cosmetic", "false");
return TranslationUtil.getTranslation("equipped-cosmetic", String.valueOf(cosmetic.getId() == user.getCosmetic(cosmetic.getSlot()).getId()));
}
case "wardrobe-enabled":