From 9a0264f5d23f08d8dc9b4484c93f630dd91738b8 Mon Sep 17 00:00:00 2001 From: redmatrix Date: Mon, 25 May 2015 19:17:35 -0700 Subject: some work on issue #329 --- include/zot.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'include/zot.php') diff --git a/include/zot.php b/include/zot.php index d719f3177..02ac1301b 100644 --- a/include/zot.php +++ b/include/zot.php @@ -1114,7 +1114,7 @@ function zot_import($arr, $sender_url) { } stringify_array_elms($recip_arr); $recips = implode(',',$recip_arr); - $r = q("select channel_hash as hash from channel where channel_hash in ( " . $recips . " ) and not ( channel_pageflags & %d )>0 ", + $r = q("select channel_hash as hash from channel where channel_hash in ( " . $recips . " ) and not ( channel_pageflags & %d ) > 0 ", intval(PAGE_REMOVED) ); if(! $r) { @@ -1378,7 +1378,8 @@ function public_recips($msg) { if(($tag['type'] === 'mention') && (strpos($tag['url'],z_root()) !== false)) { $address = basename($tag['url']); if($address) { - $z = q("select channel_hash as hash from channel where channel_address = '%s' limit 1", + $z = q("select channel_hash as hash from channel where channel_address = '%s' + and ( channel_pageflags & " . intval(PAGE_REMOVED) . " ) = 0 limit 1", dbesc($address) ); if($z) @@ -1482,7 +1483,7 @@ function allowed_public_recips($msg) { $condensed_recips[] = $rr['hash']; $results = array(); - $r = q("select channel_hash as hash from channel left join abook on abook_channel = channel_id where abook_xchan = '%s' and not ( channel_pageflags & %d ) > 0 ", + $r = q("select channel_hash as hash from channel left join abook on abook_channel = channel_id where abook_xchan = '%s' and ( channel_pageflags & %d ) = 0 ", dbesc($hash), intval(PAGE_REMOVED) ); -- cgit v1.2.3