public IActionResult Delete(int id) { Player player = dataRepository.GetById(id); if (player == null) { return(NotFound("The player record could not be found!")); } dataRepository.Delete(player); return(NoContent()); }