MCPcopy
hub / github.com/gofiber/fiber / releaseSession

Function releaseSession

middleware/session/session.go:92–104  ·  view source on GitHub ↗
(s *Session)

Source from the content-addressed store, hash-verified

90}
91
92func releaseSession(s *Session) {
93 s.mu.Lock()
94 s.id = ""
95 s.idleTimeout = 0
96 s.ctx = nil
97 s.config = nil
98 s.extractor = extractors.Extractor{}
99 if s.data != nil {
100 s.data.Reset()
101 }
102 s.mu.Unlock()
103 sessionPool.Put(s)
104}
105
106// Fresh returns whether the session is new
107//

Callers 3

NewWithStoreFunction · 0.85
saveSessionMethod · 0.85
ReleaseMethod · 0.85

Calls 4

LockMethod · 0.65
ResetMethod · 0.65
UnlockMethod · 0.65
PutMethod · 0.65

Tested by

no test coverage detected