fixed: anonymous registration with email confirmation is broken
This commit is contained in:
parent
976834a5a4
commit
64a6976a25
2 changed files with 8 additions and 6 deletions
|
|
@ -1,4 +1,5 @@
|
|||
7.6.0
|
||||
- fixed: anonymous registration with email confirmation is broken
|
||||
- added an epochDate field to the template for CS RSS items. The ^D();
|
||||
macro can then format the epoch date.
|
||||
- fixed: actove admin console tab isn't highlighted
|
||||
|
|
|
|||
|
|
@ -250,18 +250,19 @@ sub createAccountSave {
|
|||
$properties->{ passwordTimeout } = $setting->get("webguiPasswordTimeout");
|
||||
$properties->{ status } = 'Deactivated' if ($setting->get("webguiValidateEmail"));
|
||||
|
||||
my $afterCreateMessage = $self->SUPER::createAccountSave($username,$properties,$password,$profile);
|
||||
|
||||
# Send validation e-mail if required
|
||||
if ($setting->get("webguiValidateEmail")) {
|
||||
my $key = $session->id->generate();
|
||||
my $key = $session->id->generate;
|
||||
$self->saveParams($self->userId,"WebGUI",{emailValidationKey=>$key});
|
||||
my $mail = WebGUI::Mail::Send->create($self->session,{
|
||||
my $mail = WebGUI::Mail::Send->create($self->session, {
|
||||
to => $profile->{email},
|
||||
subject => $i18n->get('email address validation email subject','AuthWebGUI')
|
||||
});
|
||||
});
|
||||
$mail->addText(
|
||||
$i18n->get('email address validation email body','AuthWebGUI') . "\n\n"
|
||||
. $session->url->getSiteURL()
|
||||
. $session->url->page("op=auth;method=validateEmail;key=".$key) . "\n\n"
|
||||
. $session->url->page("op=auth;method=validateEmail;key=".$key, 'full') . "\n\n"
|
||||
);
|
||||
$mail->addFooter;
|
||||
$mail->send;
|
||||
|
|
@ -273,7 +274,7 @@ sub createAccountSave {
|
|||
$self->logout;
|
||||
return $self->displayLogin($i18n->get('check email for validation','AuthWebGUI'));
|
||||
}
|
||||
return $self->SUPER::createAccountSave($username,$properties,$password,$profile);
|
||||
return $afterCreateMessage;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue