--- /recenttopicsindex.php Wed Aug 04 13:18:34 2010
+++ /recenttopicsindex.php Tue Dec 28 10:20:54 2010
@@ -87,7 +87,7 @@
function recenttopicsindex_show()
{
- global $db, $mybb, $page, $recenttopics, $theme, $lang;
+ global $db, $mybb, $page, $recenttopics, $theme, $lang, $permissioncache;
$lang->load('recenttopicsindex');
@@ -107,6 +107,13 @@
</thead>';
// Run the Query
+ // !!! FIX private forum exposure!!!
+ if ( !is_array($permissioncache) ||
+ (is_array($permissioncache) && ((count($permissioncache)==1) && (isset($permissioncache['-1']) && ($permissioncache['-1'] = "1"))))
+ ) {
+ $permissioncache = forum_permissions();
+ }
+
$unsearchforums = get_unsearchable_forums();
if($unsearchforums)
$where_sql .= " AND t.fid NOT IN ($unsearchforums)";