Commit 7b70b779 authored by Nicolas Meyer's avatar Nicolas Meyer Committed by Bojan Zivanovic

Quick fix about the username and password changed during install - Username...

Quick fix about the username and password changed during install - Username was left at the custom value even if the checkbox was unchecked after changing the values.

Change-Id: I0524c20871974c16231a76133625c5fb10fa3f3f
Reviewed-on: https://code.drupalcommerce.org/143Tested-by: default avatarJenkins <jenkins@commerceguys.com>
Reviewed-by: default avatarBojan Zivanovic <bojan@commerceguys.com>
parent 3fefd5e2
......@@ -83,13 +83,13 @@ function commerce_kickstart_custom_setting(&$form, &$form_state) {
// Use our custom values only the corresponding checkbox is checked.
if ($form_state['values']['override_account_informations'] == TRUE) {
if ($form_state['input']['pass']['pass1'] == $form_state['input']['pass']['pass2']) {
$form_state['values']['account']['name'] = $form_state['values']['name'];
$form_state['values']['account']['pass'] = $form_state['input']['pass']['pass1'];
}
else {
form_error($form_state['input']['pass'], t('The specified passwords do not match.'));
else {
form_set_error('pass', t('The specified passwords do not match.'));
}
}
$form_state['values']['account']['name'] = $form_state['values']['name'];
}
/**
......
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