Browse Source

Merge pull request #149 from Laykou/patch-1

Fix integer to seconds in remember_otp_session_for_seconds
master
Dmitrii Golub 7 years ago committed by GitHub
parent
commit
85460400f3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      app/controllers/devise/two_factor_authentication_controller.rb

2
app/controllers/devise/two_factor_authentication_controller.rb

@ -47,7 +47,7 @@ class Devise::TwoFactorAuthenticationController < DeviseController
if expires_seconds && expires_seconds > 0
cookies.signed[TwoFactorAuthentication::REMEMBER_TFA_COOKIE_NAME] = {
value: "#{resource.class}-#{resource.public_send(Devise.second_factor_resource_id)}",
expires: expires_seconds.from_now
expires: expires_seconds.seconds.from_now
}
end
end

Loading…
Cancel
Save