Fix test failure #3047

This commit is contained in:
Muqsit 2019-07-19 12:26:00 +00:00 committed by Dylan K. Taylor
parent a8fa3ba434
commit 5e8c92b1da

View File

@ -283,7 +283,7 @@ class Item implements ItemIds, \JsonSerializable{
$display = $tag->getCompoundTag(self::TAG_DISPLAY);
if($display !== null){
$this->customName = $display->getString(self::TAG_DISPLAY_NAME, $this->customName, true);
$lore = $tag->getListTag(self::TAG_DISPLAY_LORE);
$lore = $display->getListTag(self::TAG_DISPLAY_LORE);
if($lore !== null and $lore->getTagType() === NBT::TAG_String){
/** @var StringTag $t */
foreach($lore as $t){