From 9631c663d52404bd163125844ceecc44979a45ac Mon Sep 17 00:00:00 2001 From: astaxie Date: Sat, 10 Aug 2013 23:58:25 +0800 Subject: [PATCH] fix #145 this.DestroySession() --- controller.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/controller.go b/controller.go index 6983b71d..50cc0f55 100644 --- a/controller.go +++ b/controller.go @@ -342,6 +342,10 @@ func (c *Controller) DelSession(name interface{}) { c.CruSession.Delete(name) } +func (c *Controller) DestroySession() { + GlobalSessions.SessionDestroy(c.Ctx.ResponseWriter, c.Ctx.Request) +} + func (c *Controller) IsAjax() bool { return (c.Ctx.Request.Header.Get("HTTP_X_REQUESTED_WITH") == "XMLHttpRequest") }