1
0
mirror of https://github.com/kataras/iris.git synced 2026-01-06 03:27:27 +00:00
This commit is contained in:
Makis Maropoulos
2016-07-01 01:38:29 +03:00
parent 82d37c5c35
commit af67a97518
5 changed files with 25 additions and 9 deletions

View File

@@ -102,7 +102,10 @@ func (s *Store) SetLastAccessedTime(lastacc time.Time) {
s.lastAccessedTime = lastacc
}
// Destroy does nothing here, to destroy the session use the manager's .Destroy func
// Destroy
func (s *Store) Destroy() {
// nothing
// clears without provider's update.
for key := range s.values {
delete(s.values, key)
}
}

View File

@@ -173,4 +173,8 @@ func (s *Store) SetLastAccessedTime(lastacc time.Time) {
func (s *Store) Destroy() {
// remove the whole value which is the s.values from real redis
redis.Delete(s.sid)
for key := range s.values {
delete(s.values, key)
}
}