Commit 2c457bbc authored by webchick's avatar webchick

Issue #1837962 by superspring, chx: Remove dead code from RegisterFormController.

parent a0ea12b3
......@@ -99,14 +99,10 @@ public function save(array $form, array &$form_state) {
$admin = $form_state['values']['administer_users'];
$notify = !empty($form_state['values']['notify']);
// Save has no return value so this cannot be tested.
// Assume save has gone through correctly.
$account->save();
// Terminate if an error occurred while saving the account.
if ($status =! SAVED_NEW) {
drupal_set_message(t("Error saving user account."), 'error');
$form_state['redirect'] = '';
return;
}
$form_state['user'] = $account;
$form_state['values']['uid'] = $account->uid;
......
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