Add time limit for inactive sessions

closes #8
This commit is contained in:
Râu Cao
2023-02-19 13:44:48 +08:00
parent 90680368fb
commit e2618de7c6
3 changed files with 7 additions and 2 deletions

View File

@@ -38,7 +38,8 @@ class User < ApplicationRecord
devise :ldap_authenticatable,
:confirmable,
:recoverable,
:validatable
:validatable,
:timeoutable
def ldap_before_save
self.email = Devise::LDAP::Adapter.get_ldap_param(self.cn, "mail").first