From 234f622f09407c20d36eed5840531d696c8ef535 Mon Sep 17 00:00:00 2001 From: Konrad Jurkowski Date: Tue, 18 Oct 2016 11:02:52 +0200 Subject: [PATCH] Removed unnecessary comma that made it impossible to sign in via cookie --- .../hooks/two_factor_authenticatable.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/two_factor_authentication/hooks/two_factor_authenticatable.rb b/lib/two_factor_authentication/hooks/two_factor_authenticatable.rb index 6ecfd70..159ae14 100644 --- a/lib/two_factor_authentication/hooks/two_factor_authenticatable.rb +++ b/lib/two_factor_authentication/hooks/two_factor_authenticatable.rb @@ -1,6 +1,6 @@ Warden::Manager.after_authentication do |user, auth, options| if auth.env["action_dispatch.cookies"] - expected_cookie_value = "#{user.class}-#{user.public_send(Devise.second_factor_resource_id)}", + expected_cookie_value = "#{user.class}-#{user.public_send(Devise.second_factor_resource_id)}" actual_cookie_value = auth.env["action_dispatch.cookies"].signed[TwoFactorAuthentication::REMEMBER_TFA_COOKIE_NAME] bypass_by_cookie = actual_cookie_value == expected_cookie_value end