public async Task <IActionResult> Put(int id, [FromBody] L_GameData gameData) { // successful update for PUT returns 204 No Content with empty body, or 200 OK if (await _gameDataRepository.GetGameDataById(id) is L_GameData oldGameData) { await _gameDataRepository.UpdateGameData(gameData); return(NoContent()); //return StatusCode(204); } return(NotFound()); }