From cdd120ed20922a3130f108ff60b47a4f2130c44d Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Thu, 31 Aug 2006 19:52:39 +0000 Subject: - Patch #77936 by moshe and rdouglass: pluggable session handling. --- modules/throttle/throttle.module | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'modules/throttle/throttle.module') diff --git a/modules/throttle/throttle.module b/modules/throttle/throttle.module index 4707aa580..de21c1497 100644 --- a/modules/throttle/throttle.module +++ b/modules/throttle/throttle.module @@ -63,13 +63,13 @@ function throttle_exit() { $throttle = module_invoke('throttle', 'status'); if ($max_guests = variable_get('throttle_anonymous', 0)) { - $guests = db_result(db_query('SELECT COUNT(sid) AS count FROM {sessions} WHERE timestamp >= %d AND uid = 0', time() - $time_period)); + $guests = sess_count(time() - $time_period, TRUE); } else { $guests = 0; } if ($max_users = variable_get('throttle_user', 0)) { - $users = db_result(db_query('SELECT COUNT(DISTINCT(uid)) AS count FROM {sessions} WHERE timestamp >= %d AND uid != 0', time() - $time_period)); + $users = sess_count(time() - $time_period, FALSE); } else { $users = 0; -- cgit v1.2.3