Skip to content

Commit

Permalink
Merge pull request #2329 from vanjarosoftware/#2328-disable-registrat…
Browse files Browse the repository at this point in the history
…ion-email

Disable registration email notification to user when email verificati…
  • Loading branch information
Gaganbird authored Jul 19, 2024
2 parents e62fe81 + 683da96 commit 1455673
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -352,8 +352,12 @@ protected static ActionResult CompleteUserCreation(UserCreateStatus createStatus
}
break;
case (int)Globals.PortalRegistrationType.PublicRegistration:
Mail.SendMail(newUser, MessageType.UserRegistrationPublic, PortalController.Instance.GetCurrentSettings() as PortalSettings);
UserController.UserLogin(PortalSettings.Current.PortalId, newUser.Username, newUser.Membership.Password, "", PortalSettings.Current.PortalName, "", ref loginStatus, false);
{
string EmailVerification = Core.Managers.SettingManager.GetValue(PortalSettings.Current.PortalId, 0, "setting_registration", "EmailVerification", null);
if (EmailVerification != "1")
Mail.SendMail(newUser, MessageType.UserRegistrationPublic, PortalController.Instance.GetCurrentSettings() as PortalSettings);
UserController.UserLogin(PortalSettings.Current.PortalId, newUser.Username, newUser.Membership.Password, "", PortalSettings.Current.PortalName, "", ref loginStatus, false);
}
break;
case (int)Globals.PortalRegistrationType.VerifiedRegistration:
Mail.SendMail(newUser, MessageType.UserRegistrationVerified, PortalController.Instance.GetCurrentSettings() as PortalSettings);
Expand Down

0 comments on commit 1455673

Please sign in to comment.