Fix merge conflicts

This commit is contained in:
aignatov-bio 2020-07-22 12:37:18 +02:00
parent ddfe8231d8
commit 005bfb2ba7

View file

@ -68,15 +68,6 @@ class Users::SessionsController < Devise::SessionsController
flash[:system_notification_modal] = true
end
protected
def remove_authenticate_mesasge_if_root_path
if session[:user_return_to] == root_path && flash[:alert] == I18n.t('devise.failure.unauthenticated')
flash[:alert] = nil
end
end
private
def authenticate_with_two_factor
user = User.find_by(id: session[:otp_user_id])
@ -120,6 +111,14 @@ class Users::SessionsController < Devise::SessionsController
end
private
def remove_authenticate_mesasge_if_root_path
if session[:user_return_to] == root_path && flash[:alert] == I18n.t('devise.failure.unauthenticated')
flash[:alert] = nil
end
end
def redirect_2fa
user = User.find_by(email: params[:user][:email])