public ActionResult RemoveSscAdmin(string id) { var user = _userRepository.GetNullableById(id); if (user == null) { ErrorMessage = string.Format("User {0} not found.", id); return(this.RedirectToAction(a => a.Index())); } if (_userIdentity.IsUserInRole(id, Role.Codes.SscAdmin) == false) { Message = id + " is not an SSC admin"; return(this.RedirectToAction(a => a.Index())); } return(View(user)); }