]> git.mxchange.org Git - friendica.git/commitdiff
Quote of quotes are visually improved
authorMichael <heluecht@pirati.ca>
Mon, 10 Oct 2022 12:30:07 +0000 (12:30 +0000)
committerMichael <heluecht@pirati.ca>
Mon, 10 Oct 2022 12:30:07 +0000 (12:30 +0000)
src/Content/Item.php
src/Protocol/Diaspora.php

index d5c33a762c6f6955bc3591d6707f8db629729eb9..53ee1462f395622d8c8758c541303227018e26ad 100644 (file)
@@ -22,7 +22,7 @@
 namespace Friendica\Content;
 
 use Friendica\Content\Text\BBCode;
-use Friendica\Content\Text\Markdown;
+use Friendica\Content\Text\HTML;
 use Friendica\Core\Hook;
 use Friendica\Core\L10n;
 use Friendica\Core\Logger;
@@ -669,8 +669,7 @@ class Item
 
                // If it is a reshared post then reformat it to avoid display problems with two share elements
                if (Diaspora::isReshare($item['body'], false)) {
-                       $item['body'] = Markdown::toBBCode(BBCode::toMarkdown($item['body']));
-                       $item['body'] = Diaspora::replacePeopleGuid($item['body'], $item['author-link']);
+                       $item['body'] = HTML::toBBCode(BBCode::convertForUriId($item['uri-id'], $item['body'], BBCode::ACTIVITYPUB));
                }
 
                $shared_content .= $item['body'] . '[/share]';
index 88665f949a029c657b7db8c11d4b9d10e0ba5591..66ace1d3db448dbb09cb496dc15d955fd41c2fb3 100644 (file)
@@ -2395,6 +2395,7 @@ class Diaspora
                $datarray = self::setDirection($datarray, $direction);
 
                $datarray['body'] = DI::contentItem()->createSharedPostByGuid($root_guid, $importer['uid'], $original_person['url']);
+               $datarray['body'] = Diaspora::replacePeopleGuid($datarray['body'], $datarray['author-link']);
 
                /// @todo Copy tag data from original post
                Tag::storeFromBody($datarray['uri-id'], $datarray['body']);