// GET: /Profile/ public ActionResult Index() { var userInfo = comUsers.GetUserInformation(); if (userInfo == null) //If session goes down { comUsers.Logout(); return(RedirectToAction("Login", "Account")); } ViewBag.User = userInfo; ViewBag.Connections = comUsers.GetUserFriends(); ViewBag.TableTitle = "Friends"; ViewBag.Friend = "Self"; return(View()); }
public ActionResult LogOff() { comUsers.Logout(); return(RedirectToAction("Index", "Home")); }