mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-04 00:59:51 +00:00
Item: fixed setCustomName() not removing display NBT tag with empty name (#3049)
This commit is contained in:
parent
26faf4a952
commit
b788982d60
@ -467,7 +467,7 @@ class Item implements ItemIds, \JsonSerializable{
|
|||||||
*/
|
*/
|
||||||
public function setCustomName(string $name) : Item{
|
public function setCustomName(string $name) : Item{
|
||||||
if($name === ""){
|
if($name === ""){
|
||||||
$this->clearCustomName();
|
return $this->clearCustomName();
|
||||||
}
|
}
|
||||||
|
|
||||||
/** @var CompoundTag $display */
|
/** @var CompoundTag $display */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user