Exemple #1
0
        private bool SendConfirmationEmail(DbUser user)
        {
            string token            = CreateUserToken(user);
            var    confirmationLink = Url.Action(nameof(ConfirmEmail), "Auth", new { token, email = user.Email }, Request.Scheme);

            return(EmailProfile.SendEmail(user.Email, confirmationLink, "ToDoApp - Confirm your email"));
        }
Exemple #2
0
        private bool SendPasswordRecoveryEmail(DbUser user)
        {
            string token            = CreateUserToken(user);
            var    confirmationLink = Url.Action(nameof(EditPassword), "Auth", new { token, id = user.UserId }, Request.Scheme);

            return(EmailProfile.SendEmail(user.Email, confirmationLink, "ToDoApp - Change your password"));
        }