refactor: update tokenSignList to slice

This commit is contained in:
weloe
2023-05-16 21:57:21 +08:00
parent 29d76d7bfb
commit 900e86123a
4 changed files with 61 additions and 38 deletions

View File

@@ -99,7 +99,7 @@ func (e *Enforcer) logoutByToken(token string) error {
}
}
// check TokenSignList length, if length == 0, delete this session
if session != nil && session.TokenSignList.Len() == 0 {
if session != nil && session.TokenSignSize() == 0 {
err = e.deleteSession(id)
if err != nil {
return err