From cc914918fa8827aa54a9071349c9ebaa7ecde94c Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Fri, 16 Jan 2009 16:45:16 +0100 Subject: [PATCH] block ccache for special cat_ids --- functions.php | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/functions.php b/functions.php index 239e74e6c..e49dd9d21 100644 --- a/functions.php +++ b/functions.php @@ -2328,6 +2328,10 @@ print ""; + $ctr = getCategoryUnread($link, -3); + + print ""; + $age_qpart = getMaxAgeSubquery(); /* $result = db_query($link, "SELECT cat_id,SUM((SELECT COUNT(int_id) @@ -4210,7 +4214,12 @@ function printCategoryHeader($link, $cat_id, $hidden = false, $can_browse = true) { $tmp_category = getCategoryTitle($link, $cat_id); - $cat_unread = ccache_find($link, $cat_id, $_SESSION["uid"], true); + + if ($cat_id > 0) { + $cat_unread = ccache_find($link, $cat_id, $_SESSION["uid"], true); + } else { + $cat_unread = getCategoryUnread($link, $cat_id); + } if ($hidden) { $holder_style = "display:none;";