- Fix broken session deleting on account blocking.

4.6.x
Steven Wittens 2005-03-01 18:44:41 +00:00
parent 9803bc4321
commit ea08f062b2
2 changed files with 4 additions and 4 deletions

View File

@ -138,8 +138,8 @@ function user_save($account, $array = array(), $category = 'account') {
}
// Delete a blocked user's sessions to kick them if they are online.
if ($user->status == 0) {
db_query('DELETE FROM {sessions} WHERE uid = %d', $user->uid);
if ($array['status'] == 0) {
db_query('DELETE FROM {sessions} WHERE uid = %d', $account->uid);
}
// Refresh user object

View File

@ -138,8 +138,8 @@ function user_save($account, $array = array(), $category = 'account') {
}
// Delete a blocked user's sessions to kick them if they are online.
if ($user->status == 0) {
db_query('DELETE FROM {sessions} WHERE uid = %d', $user->uid);
if ($array['status'] == 0) {
db_query('DELETE FROM {sessions} WHERE uid = %d', $account->uid);
}
// Refresh user object