return item lore back rather than nulling it

This commit is contained in:
hyperdefined
2023-02-20 22:02:48 -05:00
parent 72b8b31779
commit 4ea9e1600b
7 changed files with 19 additions and 61 deletions

View File

@@ -21,6 +21,7 @@ import lol.hyper.toolstats.ToolStats;
import org.bukkit.inventory.meta.ItemMeta;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Locale;
@@ -47,7 +48,7 @@ public class ItemLore {
if (configLore == null || configLoreRaw == null) {
toolStats.logger.warning("There is no lore message for messages." + configLorePath + "!");
toolStats.logger.warning("Unable to update lore for item.");
return null;
return itemMeta.getLore();
}
List<String> newLore;
@@ -118,7 +119,7 @@ public class ItemLore {
if (dateCreated == null || itemOwner == null) {
toolStats.logger.warning("There is no lore message for messages." + type.toLowerCase(Locale.ENGLISH) + "!");
toolStats.logger.warning("Unable to update lore for item.");
return null;
return itemMeta.getLore();
}
List<String> newLore;