From 595b1f485ac4bf0d6f78fd6191ad6337d2f5bb44 Mon Sep 17 00:00:00 2001 From: natdeanlewissoftwire Date: Fri, 7 Jul 2023 11:39:45 +0100 Subject: [PATCH] feat: skip reconfirmation on update --- app/controllers/users_controller.rb | 1 + app/mailers/devise_notify_mailer.rb | 12 ------------ 2 files changed, 1 insertion(+), 12 deletions(-) diff --git a/app/controllers/users_controller.rb b/app/controllers/users_controller.rb index 31df38da7..e1c7cb471 100644 --- a/app/controllers/users_controller.rb +++ b/app/controllers/users_controller.rb @@ -46,6 +46,7 @@ class UsersController < ApplicationController end def update + @user.skip_reconfirmation! if @user.update(user_params) if @user == current_user bypass_sign_in @user diff --git a/app/mailers/devise_notify_mailer.rb b/app/mailers/devise_notify_mailer.rb index 5560e7925..a11d227c2 100644 --- a/app/mailers/devise_notify_mailer.rb +++ b/app/mailers/devise_notify_mailer.rb @@ -69,16 +69,4 @@ private personalisation(record, token, url, username:), ) end - - # def unlock_instructions(record, token, opts = {}) - # super - # end - # - # def email_changed(record, opts = {}) - # super - # end - # - # def password_change(record, opts = {}) - # super - # end end