Commit 899123af authored by drumm's avatar drumm

#70302 by adixon and killes, avoid deleting uid 0 on duplicate deletions.

parent bbff6a9b
......@@ -1400,6 +1400,10 @@ function user_edit($category = 'account') {
global $user;
$account = user_load(array('uid' => arg(1)));
if ($account === FALSE) {
drupal_set_message(t('The account does not exist or has already been deleted.'));
drupal_goto('admin/user');
}
$edit = $_POST['op'] ? $_POST['edit'] : (array)$account;
if (arg(2) == 'delete') {
......
......@@ -1400,6 +1400,10 @@ function user_edit($category = 'account') {
global $user;
$account = user_load(array('uid' => arg(1)));
if ($account === FALSE) {
drupal_set_message(t('The account does not exist or has already been deleted.'));
drupal_goto('admin/user');
}
$edit = $_POST['op'] ? $_POST['edit'] : (array)$account;
if (arg(2) == 'delete') {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment