public ActionResult Logout() { var httpCookie = this.Request.Cookies.Get("sessionId"); if (httpCookie == null || !AuthenticatedManager.IsAuthenticated(httpCookie.Value)) { return(this.RedirectToAction("Login")); } AuthenticatedManager.Logout(Request.Cookies.Get("sessionId").Value); return(this.RedirectToAction("All", "Cars")); }
public void Logout(HttpResponse response, HttpSession session) { AuthenticatedManager.Logout(response, session.Id); this.Redirect(response, "/home/topics"); }