allow fill gui item to be air

instead of printing error on stats failure, just print a warning
This commit is contained in:
okx-code
2018-08-30 23:39:09 +01:00
parent 0bf3dd2a06
commit 6ba4dcb4d0
4 changed files with 7 additions and 3 deletions
+4
View File
@@ -70,6 +70,10 @@ public class Gui implements InventoryHolder {
item = new ItemStack(material);
}
if(item.getType() == Material.AIR && section.getName().equalsIgnoreCase("fill")) {
return item;
}
ItemMeta meta = item.getItemMeta();
if (section.contains("lore")) {
meta.setLore(Arrays.stream(format(section.getString("lore"), player, oldRank, rank).split("\n"))