public IActionResult Edit() { try { _athleteService.Edit(); return(RedirectToAction(nameof(Index))); } catch (MySqlException) { return(RedirectToAction(nameof(Error), new { message = "Error while trying to access the database for editing." })); } }