Issue 14055: Set link to group server for group posts

This commit is contained in:
Michael 2024-04-07 15:46:55 +00:00
parent ad65e56b16
commit a2da42640c
1 changed files with 7 additions and 0 deletions

View File

@ -3990,6 +3990,13 @@ class Item
$plink = $item['uri'];
}
if (($item['post-reason'] == self::PR_ANNOUNCEMENT) && ($item['owner-contact-type'] == Contact::TYPE_COMMUNITY) && ($item['owner-network'] == Protocol::DFRN)) {
$contact = Contact::getById($item['owner-id'], ['baseurl']);
if (!empty($contact['baseurl'])) {
$plink = $contact['baseurl'] . '/display/' . $item['guid'];
}
}
if (DI::userSession()->getLocalUserId()) {
$ret = [
'href' => "display/" . $item['guid'],