Applied rector with PHP8.1 migration rules

This commit is contained in:
Jan Böhmer 2023-06-11 14:15:46 +02:00
parent dc6a67c2f0
commit 7ee01d9a05
303 changed files with 1228 additions and 3465 deletions

View file

@ -45,11 +45,10 @@ class EventCommentHelper
{
protected const MAX_MESSAGE_LENGTH = 255;
protected ?string $message;
protected ?string $message = null;
public function __construct()
{
$this->message = null;
}
/**
@ -60,11 +59,7 @@ class EventCommentHelper
public function setMessage(?string $message): void
{
//Restrict the length of the string
if ($message) {
$this->message = mb_strimwidth($message, 0, self::MAX_MESSAGE_LENGTH, '...');
} else {
$this->message = null;
}
$this->message = $message ? mb_strimwidth($message, 0, self::MAX_MESSAGE_LENGTH, '...') : null;
}
/**