public async Task <Player> CreatePlayer(Player newPlayer) { if (newPlayer is null) { throw new NullReferenceException(); } await _uow.Players.AddAsync(newPlayer); await _uow.CommitAsync(); return(newPlayer); }
public async Task <Game> CreateGame(Game newGame) { if (newGame is null) { throw new NullReferenceException(); } await _uow.Games.AddAsync(newGame); await _uow.CommitAsync(); return(newGame); }