public IActionResult Update(string id, Sport sportIn) { var sport = _sportService.Get(id); if (sport == null) { return(NotFound()); } if (sportIn == null) { return(BadRequest()); } else { sportIn.Id = id; } _sportService.Update(id, sportIn); return(NoContent()); }