diff options
author | Dries Buytaert <dries@buytaert.net> | 2006-08-31 19:52:39 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2006-08-31 19:52:39 +0000 |
commit | cdd120ed20922a3130f108ff60b47a4f2130c44d (patch) | |
tree | 588404ad09a0705f50699000ac5f7d1d5fda07c2 /modules/throttle | |
parent | c29daaaabb7ddb188ea9030c06049c63529844fa (diff) | |
download | brdo-cdd120ed20922a3130f108ff60b47a4f2130c44d.tar.gz brdo-cdd120ed20922a3130f108ff60b47a4f2130c44d.tar.bz2 |
- Patch #77936 by moshe and rdouglass: pluggable session handling.
Diffstat (limited to 'modules/throttle')
-rw-r--r-- | modules/throttle/throttle.module | 4 |
1 files changed, 2 insertions, 2 deletions
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; |