From b200874f17686cc2b1c8eb4acb760572b79aff0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roland=20H=C3=A4der?= Date: Thu, 16 Jun 2022 13:38:40 +0200 Subject: [PATCH] Ops: - wrong way around (!empty($foo)) is proper - also needed to be checked on $acitivty['content'] --- src/Protocol/ActivityPub/Processor.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Protocol/ActivityPub/Processor.php b/src/Protocol/ActivityPub/Processor.php index f723d287b9..31a37a36f1 100644 --- a/src/Protocol/ActivityPub/Processor.php +++ b/src/Protocol/ActivityPub/Processor.php @@ -616,8 +616,8 @@ class Processor $content = $activity['content']; } else { // By default assume "text/html" - $item['title'] = (empty($activity['name']) ? HTML::toBBCode($activity['name']) : ''); - $content = HTML::toBBCode($activity['content']); + $item['title'] = (!empty($activity['name']) ? HTML::toBBCode($activity['name']) : ''); + $content = (!empty($activity['content']) ? HTML::toBBCode($activity['content']) : ''); } $item['title'] = trim(BBCode::toPlaintext($item['title']));