diff options
author | redmatrix <redmatrix@redmatrix.me> | 2015-05-25 19:17:35 -0700 |
---|---|---|
committer | redmatrix <redmatrix@redmatrix.me> | 2015-05-25 19:17:35 -0700 |
commit | 9a0264f5d23f08d8dc9b4484c93f630dd91738b8 (patch) | |
tree | 6d6e4eee4bd11adc7f6c6e8b2a6d40ae8003ba2b /include | |
parent | 29a8d580be141ee451e4f5b02870e9fe384e3ed6 (diff) | |
download | volse-hubzilla-9a0264f5d23f08d8dc9b4484c93f630dd91738b8.tar.gz volse-hubzilla-9a0264f5d23f08d8dc9b4484c93f630dd91738b8.tar.bz2 volse-hubzilla-9a0264f5d23f08d8dc9b4484c93f630dd91738b8.zip |
some work on issue #329
Diffstat (limited to 'include')
-rwxr-xr-x | include/diaspora.php | 5 | ||||
-rw-r--r-- | include/identity.php | 5 | ||||
-rw-r--r-- | include/zot.php | 7 |
3 files changed, 10 insertions, 7 deletions
diff --git a/include/diaspora.php b/include/diaspora.php index 9b2e4623a..b532822bf 100755 --- a/include/diaspora.php +++ b/include/diaspora.php @@ -24,8 +24,9 @@ function diaspora_dispatch_public($msg) { // find everybody following or allowing this author - $r = q("SELECT * from channel where channel_id in ( SELECT abook_channel from abook left join xchan on abook_xchan = xchan_hash WHERE xchan_network like '%%diaspora%%' and xchan_addr = '%s' )", - dbesc($msg['author']) + $r = q("SELECT * from channel where channel_id in ( SELECT abook_channel from abook left join xchan on abook_xchan = xchan_hash WHERE xchan_network like '%%diaspora%%' and xchan_addr = '%s' ) and ( channel_pageflags & %d ) = 0 ", + dbesc($msg['author']), + intval(PAGE_REMOVED) ); // also need to look for those following public streams diff --git a/include/identity.php b/include/identity.php index dec3f6e98..06d8a4cf8 100644 --- a/include/identity.php +++ b/include/identity.php @@ -621,8 +621,9 @@ function profile_load(&$a, $nickname, $profile = '') { logger('profile_load: ' . $nickname . (($profile) ? ' profile: ' . $profile : '')); - $user = q("select channel_id from channel where channel_address = '%s' limit 1", - dbesc($nickname) + $user = q("select channel_id from channel where channel_address = '%s' and not ( channel_pageflags & %d ) > 0 limit 1", + dbesc($nickname), + intval(PAGE_REMOVED) ); if(! $user) { 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) ); |