(now time.Time)
| 394 | } |
| 395 | |
| 396 | func (s *Server) pruneExpiredSessionsLocked(now time.Time) { |
| 397 | for id, currentSession := range s.sessions { |
| 398 | if currentSession == nil || sessionExpired(currentSession, now) { |
| 399 | delete(s.sessions, id) |
| 400 | } |
| 401 | } |
| 402 | } |
| 403 | |
| 404 | func (s *Server) pruneLeastRecentlyUsedSessionsLocked(count int) { |
| 405 | for range count { |
no test coverage detected