New function to convert BBCode for a given ID

This commit is contained in:
Michael 2021-07-08 13:47:46 +00:00
parent f3452d86c4
commit f29bd23ea8
15 changed files with 145 additions and 38 deletions

View file

@ -1109,7 +1109,7 @@ class Feed
$body = OStatus::formatPicturePost($item['body'], $item['uri-id']);
$body = BBCode::convert($body, false, BBCode::OSTATUS, false, $item['uri-id']);
$body = BBCode::convertForItem($item['uri-id'], $body, BBCode::OSTATUS, false);
XML::addElement($doc, $entry, "content", $body, ["type" => "html"]);
@ -1186,7 +1186,7 @@ class Feed
private static function getTitle(array $item)
{
if ($item['title'] != '') {
return BBCode::convert($item['title'], false, BBCode::OSTATUS, false, $item['uri-id']);
return BBCode::convertForItem($item['uri-id'], $item['title'], BBCode::OSTATUS);
}
// Fetch information about the post