mirror of
https://github.com/friendica/friendica
synced 2024-12-22 17:20:16 +00:00
Fix fatal error in notifications
This commit is contained in:
parent
d63edf5dfa
commit
f9a3b67318
1 changed files with 3 additions and 3 deletions
|
@ -77,7 +77,7 @@ class Notify extends BaseEntity
|
|||
protected $verb;
|
||||
/** @var string */
|
||||
protected $otype;
|
||||
/** @var string */
|
||||
/** @var string|null */
|
||||
protected $name_cache;
|
||||
/** @var string|null */
|
||||
protected $msg_cache;
|
||||
|
@ -88,7 +88,7 @@ class Notify extends BaseEntity
|
|||
/** @var int|null */
|
||||
protected $id;
|
||||
|
||||
public function __construct(int $type, string $name, UriInterface $url, UriInterface $photo, DateTime $date, int $uid, UriInterface $link, bool $seen, string $verb, string $otype, string $name_cache, string $msg = null, string $msg_cache = null, int $itemId = null, int $uriId = null, int $parent = null, ?int $parentUriId = null, ?int $id = null)
|
||||
public function __construct(int $type, string $name, UriInterface $url, UriInterface $photo, DateTime $date, int $uid, UriInterface $link, bool $seen, string $verb, string $otype, string $name_cache = null, string $msg = null, string $msg_cache = null, int $itemId = null, int $uriId = null, int $parent = null, ?int $parentUriId = null, ?int $id = null)
|
||||
{
|
||||
$this->type = $type;
|
||||
$this->name = $name;
|
||||
|
@ -118,7 +118,7 @@ class Notify extends BaseEntity
|
|||
public function updateMsgFromPreamble($epreamble)
|
||||
{
|
||||
$this->msg = Renderer::replaceMacros($epreamble, ['$itemlink' => $this->link->__toString()]);
|
||||
$this->msg_cache = self::formatMessage($this->name_cache, BBCode::toPlaintext($this->msg, false));
|
||||
$this->msg_cache = self::formatMessage($this->name_cache ?? $this->name, BBCode::toPlaintext($this->msg, false));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue