From e17694da73aca3685fdca5cc9b434f1202e84630 Mon Sep 17 00:00:00 2001 From: Shivam Mishra Date: Wed, 27 Aug 2025 14:28:52 +0530 Subject: [PATCH] refactor: use from_email method --- app/controllers/omniauth_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/omniauth_controller.rb b/app/controllers/omniauth_controller.rb index e5ef58eb9..34f7347c7 100644 --- a/app/controllers/omniauth_controller.rb +++ b/app/controllers/omniauth_controller.rb @@ -17,7 +17,7 @@ class OmniauthController < ApplicationController if auth.present? # Find existing user by email email = auth['info']['email'] - user = User.find_by(email: email) + user = User.from_email(email) if user # Create authentication token (DeviseTokenAuth way)