aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Fischer <bantu@phpbb.com>2009-12-11 16:18:56 +0000
committerAndreas Fischer <bantu@phpbb.com>2009-12-11 16:18:56 +0000
commitafa8dcb42a5a264d1f6e1f7a3f4a5889c3b5aa66 (patch)
treefda3b378555e1531abe3fddba568c12744c4eae0 /phpBB/feed.php
parentBring back caching. (diff)
downloadphpbb-afa8dcb42a5a264d1f6e1f7a3f4a5889c3b5aa66.tar.gz
phpbb-afa8dcb42a5a264d1f6e1f7a3f4a5889c3b5aa66.tar.bz2
phpbb-afa8dcb42a5a264d1f6e1f7a3f4a5889c3b5aa66.zip
Bug #54345 - Do not deliver topics from unreadable forums in the news feed.
git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@10317 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/feed.php')
-rw-r--r--phpBB/feed.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/phpBB/feed.php b/phpBB/feed.php
index e644afe642..98e8e61349 100644
--- a/phpBB/feed.php
+++ b/phpBB/feed.php
@@ -958,7 +958,7 @@ class phpbb_feed_news extends phpbb_feed_base
function get_sql()
{
- global $db, $config;
+ global $auth, $config, $db;
// Get news forums...
$sql = 'SELECT forum_id
@@ -969,6 +969,12 @@ class phpbb_feed_news extends phpbb_feed_base
$in_fid_ary = array();
while ($row = $db->sql_fetchrow($result))
{
+ // Make sure we can read this forum
+ if (!$auth->acl_get('f_read', (int) $row['forum_id']))
+ {
+ continue;
+ }
+
$in_fid_ary[] = (int) $row['forum_id'];
}
$db->sql_freeresult($result);