diff options
author | friendica <info@friendica.com> | 2014-03-26 16:09:07 -0700 |
---|---|---|
committer | friendica <info@friendica.com> | 2014-03-26 16:09:07 -0700 |
commit | 79f5fd8e2a4959b78cf8be6312962849e14e9d85 (patch) | |
tree | e245fc0558f7639daef304a462823920b3cafedc /include/security.php | |
parent | bd7be38da5fea67d2302693e28a4c070cdad8f4b (diff) | |
download | volse-hubzilla-79f5fd8e2a4959b78cf8be6312962849e14e9d85.tar.gz volse-hubzilla-79f5fd8e2a4959b78cf8be6312962849e14e9d85.tar.bz2 volse-hubzilla-79f5fd8e2a4959b78cf8be6312962849e14e9d85.zip |
allow zotfeed to create a firehose of a site.
Diffstat (limited to 'include/security.php')
-rw-r--r-- | include/security.php | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/include/security.php b/include/security.php index f52615357..6b20e2904 100644 --- a/include/security.php +++ b/include/security.php @@ -346,8 +346,9 @@ function stream_perms_api_uids($perms_min = PERMS_SITE) { $ret = array(); if(local_user()) $ret[] = local_user(); - $r = q("select channel_id from channel where channel_r_stream > 0 and channel_r_stream <= %d", - intval($perms_min) + $r = q("select channel_id from channel where channel_r_stream > 0 and channel_r_stream <= %d and not (channel_pageflags & %d) ", + intval($perms_min), + intval(PAGE_ADULT) ); if($r) foreach($r as $rr) @@ -361,7 +362,7 @@ function stream_perms_api_uids($perms_min = PERMS_SITE) { $str .= ','; $str .= intval($rr); } -logger('stream_perms_api_uids: ' . $str); +logger('stream_perms_api_uids: ' . $str, LOGGER_DEBUG); return $str; } @@ -370,8 +371,9 @@ function stream_perms_xchans($perms_min = PERMS_SITE) { if(local_user()) $ret[] = get_observer_hash(); - $r = q("select channel_hash from channel where channel_r_stream > 0 and channel_r_stream <= %d", - intval($perms_min) + $r = q("select channel_hash from channel where channel_r_stream > 0 and channel_r_stream <= %d and not (channel_pageflags & %d)", + intval($perms_min), + intval(PAGE_ADULT) ); if($r) foreach($r as $rr) @@ -385,6 +387,6 @@ function stream_perms_xchans($perms_min = PERMS_SITE) { $str .= ','; $str .= "'" . dbesc($rr) . "'"; } -logger('stream_perms_xchans: ' . $str); +logger('stream_perms_xchans: ' . $str, LOGGER_DEBUG); return $str; } |