diff options
Diffstat (limited to 'include/zot.php')
-rw-r--r-- | include/zot.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/zot.php b/include/zot.php index 71f720a6d..018f00ba5 100644 --- a/include/zot.php +++ b/include/zot.php @@ -346,12 +346,12 @@ function zot_refresh($them,$channel = null) { if($z) proc_run('php','include/notifier.php','permission_update',$z[0]['abook_id']); } - $new_connection = q("select abook_id from abook where abook_channel = %d and abook_xchan = '%s' order by abook_created desc limit 1", + $new_connection = q("select abook_id, abook_flags from abook where abook_channel = %d and abook_xchan = '%s' order by abook_created desc limit 1", intval($channel['channel_id']), dbesc($x['hash']) ); - if($new_connection && ($their_perms & PERMS_R_STREAM)) + if($new_connection && (! ($new_connection[0]['abook_flags'] & ABOOK_FLAG_PENDING)) && ($their_perms & PERMS_R_STREAM)) proc_run('php','include/onepoll.php',$new_connection[0]['abook_id']); } |