mirror of
https://github.com/kataras/iris.git
synced 2026-03-06 08:25:59 +00:00
Add session.Destroy (before I've added: Increment & Decrement entry helpers as well) | Improve the debug messages for the controllers
Former-commit-id: f5f17b05252a5032ace1e2d0fdd2304fc4004635
This commit is contained in:
@@ -31,6 +31,16 @@ type (
|
||||
}
|
||||
)
|
||||
|
||||
// Destroy destroys this session, it removes all sessions and flash values,
|
||||
// the session entry from the server and updates the registered session databases,
|
||||
// note that this method does NOT removes the client's cookie, although
|
||||
// it should be re-seted if new session is attached to that (client).
|
||||
//
|
||||
// Use the session's manager `Destroy(ctx)` in order to remove the cookie as well.
|
||||
func (s *Session) Destroy() {
|
||||
s.provider.deleteSession(s)
|
||||
}
|
||||
|
||||
// ID returns the session's ID.
|
||||
func (s *Session) ID() string {
|
||||
return s.sid
|
||||
|
||||
Reference in New Issue
Block a user