Move the plink functionality to the right function

This commit is contained in:
Michael 2022-05-05 07:57:52 +00:00
parent d34432c517
commit 4d359b7de1
2 changed files with 7 additions and 17 deletions

View file

@ -3200,6 +3200,12 @@ class Item
'orig_title' => DI::l10n()->t('View on separate page'),
];
if (!empty($plink) && ($item['private'] == self::PRIVATE)) {
$author = ['uid' => 0, 'id' => $item['author-id'],
'network' => $item['author-network'], 'url' => $item['author-link']];
$plink = Contact::magicLinkByContact($author, $plink);
}
if (!empty($plink)) {
$ret['href'] = DI::baseUrl()->remove($plink);
$ret['title'] = DI::l10n()->t('Link to source');