From 13ca56d38041c9da499bba54c1ebbaf98baa68cd Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Mon, 18 Feb 2019 14:27:01 +0100 Subject: if local_channel() and updating the page do not query for another item if the first query returned no results. we will most probably find an item from another channel (e.g. after liking a comment) and end up with multiple items with the same mid from different channels after the page update --- Zotlabs/Module/Display.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'Zotlabs/Module') diff --git a/Zotlabs/Module/Display.php b/Zotlabs/Module/Display.php index e3691702d..04e5f9fce 100644 --- a/Zotlabs/Module/Display.php +++ b/Zotlabs/Module/Display.php @@ -178,8 +178,7 @@ class Display extends \Zotlabs\Web\Controller { $static = ((array_key_exists('static',$_REQUEST)) ? intval($_REQUEST['static']) : 0); - - + $simple_update = (($update) ? " AND item_unseen = 1 " : ''); if($update && $_SESSION['loadtime']) @@ -314,7 +313,7 @@ class Display extends \Zotlabs\Web\Controller { } } - if(! $r) { + if($r === null) { // in case somebody turned off public access to sys channel content using permissions // make that content unsearchable by ensuring the owner_xchan can't match if(! perm_is_allowed($sysid,$observer_hash,'view_stream')) -- cgit v1.2.3