$content = self::removeImplicitMentionsFromBody($content, $parent);
}
- $item['content-warning'] = HTML::toBBCode($activity['summary']);
+ $item['content-warning'] = (!empty($activity['summary']) ? HTML::toBBCode($activity['summary']) : '');
$item['raw-body'] = $item['body'] = $content;
}
$attributed_to = JsonLD::fetchElement($activity['as:object'], 'as:attributedTo', '@id');
$authorid = Contact::getIdForURL($attributed_to);
- $body = HTML::toBBCode(JsonLD::fetchElement($activity['as:object'], 'as:content', '@value'));
+ $value = JsonLD::fetchElement($activity['as:object'], 'as:content', '@value');
+ $body = (!empty($value) ? HTML::toBBCode($value) : '');
$messageTags = [];
$tags = Receiver::processTags(JsonLD::fetchElementArray($activity['as:object'], 'as:tag') ?? []);