X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=lib%2Fimplugin.php;h=457c9dba5252d9528c3d5eb0568e97820d3d3cd6;hb=d4be5349b30f49fa049dbfc854bb2a95eeb1d5c1;hp=742147dbbdc90ae3502fd88f9c62a3a8273d6d45;hpb=f1d9d8a6eded2d597d5a3157febc2de09c93d3a1;p=quix0rs-gnu-social.git diff --git a/lib/implugin.php b/lib/implugin.php index 742147dbbd..457c9dba52 100644 --- a/lib/implugin.php +++ b/lib/implugin.php @@ -364,13 +364,16 @@ abstract class ImPlugin extends Plugin protected function formatNotice(Notice $notice) { $profile = $notice->getProfile(); + $nicknames = $profile->getNickname(); try { $parent = $notice->getParent(); $orig_profile = $parent->getProfile(); - $nicknames = sprintf('%1$s => %2$s', $profile->nickname, $orig_profile->nickname); + $nicknames = sprintf('%1$s => %2$s', $profile->getNickname(), $orig_profile->getNickname()); } catch (NoParentNoticeException $e) { - $nicknames = $profile->nickname; + // Not a reply, no parent notice stored + } catch (NoResultException $e) { + // Parent notice was probably deleted } return sprintf('%1$s: %2$s [%3$u]', $nicknames, $notice->content, $notice->id);