public ActionResult Create(EventType eventtype) { if (!ModelState.IsValid) { return(View()); } _eventtypeRepository.InsertOrUpdate(eventtype); _eventtypeRepository.Save(); if (Session != null) { return(Session["LoggedUserRole"].Equals("Admin") ? RedirectToAction("Index") : RedirectToAction("UserManager", "User", new { id = Session["LoggedUserId"] })); } return(RedirectToAction("Index")); }