mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-05 01:29:55 +00:00
GiveCommand: remove useless clone
addItem() clones this anyway.
This commit is contained in:
parent
f3bd48e6cb
commit
a888ab0257
@ -89,7 +89,7 @@ class GiveCommand extends VanillaCommand{
|
|||||||
}
|
}
|
||||||
|
|
||||||
//TODO: overflow
|
//TODO: overflow
|
||||||
$player->getInventory()->addItem(clone $item);
|
$player->getInventory()->addItem($item);
|
||||||
|
|
||||||
Command::broadcastCommandMessage($sender, new TranslationContainer(KnownTranslationKeys::COMMANDS_GIVE_SUCCESS, [
|
Command::broadcastCommandMessage($sender, new TranslationContainer(KnownTranslationKeys::COMMANDS_GIVE_SUCCESS, [
|
||||||
$item->getName() . " (" . $item->getId() . ":" . $item->getMeta() . ")",
|
$item->getName() . " (" . $item->getId() . ":" . $item->getMeta() . ")",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user