function user_user_operations_unblock
Callback function for admin mass unblocking users.
2 string references to 'user_user_operations_unblock'
- hook_user_operations in modules/
user/ user.api.php - Add mass user operations.
- user_user_operations in modules/
user/ user.module - Implements hook_user_operations().
File
-
modules/
user/ user.module, line 3318
Code
function user_user_operations_unblock($accounts) {
$accounts = user_load_multiple($accounts);
foreach ($accounts as $account) {
// Skip unblocking user if they are already unblocked.
if ($account !== FALSE && $account->status == 0) {
user_save($account, array(
'status' => 1,
));
}
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.