From 5c4301369235b7f03a4654e81ded6b9da3b98891 Mon Sep 17 00:00:00 2001 From: Mario Date: Thu, 9 Jan 2020 08:20:01 +0000 Subject: deal with situations where we do not have an xchan_addr but only an xchan_url --- include/conversation.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'include/conversation.php') diff --git a/include/conversation.php b/include/conversation.php index e8b8051bb..a80adb933 100644 --- a/include/conversation.php +++ b/include/conversation.php @@ -1010,11 +1010,11 @@ function thread_author_menu($item, $mode = '') { $contact = App::$contacts[$item['author_xchan']]; } else { - if($local_channel && $item['author']['xchan_addr'] && (! in_array($item['author']['xchan_network'],[ 'rss', 'anon','unknown' ]))) { - $follow_url = z_root() . '/follow/?f=&url=' . urlencode($item['author']['xchan_addr']) . '&interactive=0'; + $url = (($item['author']['xchan_addr']) ? $item['author']['xchan_addr'] : $item['author']['xchan_url']); + if($local_channel && $url && (! in_array($item['author']['xchan_network'],[ 'rss', 'anon','unknown' ]))) { + $follow_url = z_root() . '/follow/?f=&url=' . urlencode($url) . '&interactive=0'; } } - if($item['uid'] > 0 && author_is_pmable($item['author'],$contact)) { $pm_url = z_root() . '/mail/new/?f=&hash=' . urlencode($item['author_xchan']); } -- cgit v1.2.3