From 71718f66b73864c68aac5d76d363200922ce46d8 Mon Sep 17 00:00:00 2001 From: steveminutillo Date: Fri, 29 Jun 2007 04:11:23 +0000 Subject: [PATCH] more bugs with admin prefs. also, I can never remember if it's =& or &=. --- fof-main.php | 6 +++--- update-quiet.php | 8 ++------ update.php | 2 +- 3 files changed, 6 insertions(+), 10 deletions(-) diff --git a/fof-main.php b/fof-main.php index 0579a01..8926920 100644 --- a/fof-main.php +++ b/fof-main.php @@ -33,7 +33,7 @@ ob_end_clean(); if(!$fof_no_login) { require_user(); - $fof_prefs_obj = FoF_Prefs::instance(); + $fof_prefs_obj =& FoF_Prefs::instance(); } require_once('simplepie/simplepie.inc'); @@ -663,7 +663,7 @@ function fof_mark_item_unread($feed_id, $id) function fof_parse($url) { - $p &= FoF_Prefs::instance(); + $p =& FoF_Prefs::instance(); $admin_prefs = $p->admin_prefs; $pie = new SimplePie(); @@ -829,7 +829,7 @@ function fof_update_feed($id) // unread or starred, not currently in the feed or within sizeof(feed) items // of being in the feed, and are over 'purge' many days old - $p &= FoF_Prefs::instance(); + $p =& FoF_Prefs::instance(); $admin_prefs = $p->admin_prefs; if($admin_prefs['purge'] != "") diff --git a/update-quiet.php b/update-quiet.php index 5646256..e04fa09 100644 --- a/update-quiet.php +++ b/update-quiet.php @@ -17,16 +17,12 @@ set_time_limit(60*10); ob_start(); $fof_no_login = true; +$fof_user_id = 1; include_once("fof-main.php"); -$p = new FoF_Prefs(1); +$p =& FoF_Prefs::instance(); $fof_admin_prefs = $p->prefs; -$result = fof_safe_query("select user_prefs from $FOF_USER_TABLE where user_id = 1"); -$row = mysql_fetch_array($result); -$fof_admin_prefs = unserialize($row['user_prefs']); -if(!isset($fof_admin_prefs['autotimeout'])) $fof_admin_prefs['autotimeout'] = 30; - $result = fof_db_get_feeds(); $feeds = array(); diff --git a/update.php b/update.php index 7245f69..81f9018 100644 --- a/update.php +++ b/update.php @@ -19,7 +19,7 @@ print("
"); $feed = $_GET['feed']; $feeds = array(); -$p = FoF_Prefs::instance(); +$p =& FoF_Prefs::instance(); $admin_prefs = $p->admin_prefs; if($feed)