public ActionResult Remove(int id) { try { Achievement achievement = _repository.Get(id); _repository.Remove(achievement); return(RedirectToAction("AchievementsManagement")); } catch (Exception e) { Console.WriteLine(e); return(View("ErrorPage")); } }