def send_reset_password_email(config, user_email): token = generate_confirmation_token(config, user_email) user = User.objects(email=user_email).first() content = RESET_PASSWORD_CONTENT % (user.username, config['DOMAIN'], token, config['DOMAIN'], token) send_email.delay(get_email_config(config), user_email, RESET_PASSWORD_SUBJECT, content)
def send_confirm_email(config, user_email): token = generate_confirmation_token(config, user_email) user = User.objects(email=user_email).first() content = CONFIRMATION_CONTENT % (user.username, config['DOMAIN'], token, config['DOMAIN'], token) send_email.delay(get_email_config(config), user_email, CONFIRMATION_SUBJECT, content)