Fixed NullPointerException when processing transactions for dyed armor

This commit is contained in:
Intelli 2023-04-09 13:19:02 -06:00
parent 7e49c95832
commit 7825f61e45

View File

@ -6,6 +6,7 @@ import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
import org.bukkit.Bukkit;
import org.bukkit.Color;
import org.bukkit.FireworkEffect;
import org.bukkit.Material;
@ -131,7 +132,7 @@ public class ItemMetaHandler {
LeatherArmorMeta meta = (LeatherArmorMeta) itemMeta;
LeatherArmorMeta subMeta = meta.clone();
meta.setColor(null);
meta.setColor(Bukkit.getServer().getItemFactory().getDefaultLeatherColor());
list.add(meta.serialize());
metadata.add(list);