From: Mikael Nordfeldth Date: Fri, 23 Jan 2015 11:40:37 +0000 (+0100) Subject: RealtimePlugin didn't handle notices without URLs X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=f81441538674987aec6301b7c8082c51f5de7706;p=quix0rs-gnu-social.git RealtimePlugin didn't handle notices without URLs --- diff --git a/plugins/Realtime/RealtimePlugin.php b/plugins/Realtime/RealtimePlugin.php index 25fa921ffe..d41f8eca42 100644 --- a/plugins/Realtime/RealtimePlugin.php +++ b/plugins/Realtime/RealtimePlugin.php @@ -320,7 +320,7 @@ class RealtimePlugin extends Plugin $act = new ApiAction('/dev/null'); $arr = $act->twitterStatusArray($notice, true); - $arr['url'] = $notice->getUrl(); + $arr['url'] = $notice->getUrl(true); $arr['html'] = htmlspecialchars($notice->rendered); $arr['source'] = htmlspecialchars($arr['source']); $arr['conversation_url'] = $notice->getConversationUrl(); @@ -333,7 +333,7 @@ class RealtimePlugin extends Plugin if (!empty($notice->repeat_of)) { $original = Notice::getKV('id', $notice->repeat_of); if ($original instanceof Notice) { - $arr['retweeted_status']['url'] = $original->getUrl(); + $arr['retweeted_status']['url'] = $original->getUrl(true); $arr['retweeted_status']['html'] = htmlspecialchars($original->rendered); $arr['retweeted_status']['source'] = htmlspecialchars($original->source); $originalProfile = $original->getProfile();