mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-07 18:32:55 +00:00
More PHP 7.1 nullables
This commit is contained in:
@ -38,7 +38,7 @@ class EntityEffectAddEvent extends EntityEffectEvent{
|
||||
* @param EffectInstance $effect
|
||||
* @param EffectInstance $oldEffect
|
||||
*/
|
||||
public function __construct(Entity $entity, EffectInstance $effect, EffectInstance $oldEffect = null){
|
||||
public function __construct(Entity $entity, EffectInstance $effect, ?EffectInstance $oldEffect = null){
|
||||
parent::__construct($entity, $effect);
|
||||
$this->oldEffect = $oldEffect;
|
||||
}
|
||||
|
@ -52,7 +52,7 @@ class PlayerChatEvent extends PlayerEvent implements Cancellable{
|
||||
* @param string $format
|
||||
* @param Player[] $recipients
|
||||
*/
|
||||
public function __construct(Player $player, string $message, string $format = "chat.type.text", array $recipients = null){
|
||||
public function __construct(Player $player, string $message, string $format = "chat.type.text", ?array $recipients = null){
|
||||
$this->player = $player;
|
||||
$this->message = $message;
|
||||
|
||||
|
Reference in New Issue
Block a user