Confirmation Emails: Add way to resend (#287)

* Add way to resend confirmation email.

* Resend confirmation email if user sets it to the same as pending

* I10n: No pending email change
This commit is contained in:
Dylan Corrales
2025-11-04 17:11:26 -05:00
committed by GitHub
parent 6f1b651b80
commit 2064d7e374
5 changed files with 22 additions and 2 deletions

View File

@@ -2,6 +2,14 @@ class UsersController < ApplicationController
before_action :set_user
before_action :ensure_admin, only: %i[reset reset_with_sample_data]
def resend_confirmation_email
if @user.resend_confirmation_email
redirect_to settings_profile_path, notice: t(".success")
else
redirect_to settings_profile_path, alert: t("no_pending_change")
end
end
def update
@user = Current.user