FIX: Session.Destroy trigger map concurrency write (#2225)

This commit is contained in:
zxfishhack 2023-10-24 20:12:14 +08:00 committed by GitHub
parent 6df3ada9c8
commit c886e3bd28
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -44,7 +44,7 @@ type (
//
// Use the session's manager `Destroy(ctx)` in order to remove the cookie instead.
func (s *Session) Destroy() {
s.provider.deleteSession(s)
s.provider.Destroy(s.sid)
}
// ID returns the session's ID.