public IEnumerable <Player> GetPlayers(int id) { Team exists = _repo.Get(id); if (exists == null) { throw new Exception("Invalid Id"); } return(_pRepo.GetPlayersByTeamId(id)); }
public IEnumerable <Player> GetPlayers(int id) { Team exists = _repo.Get(id); if (exists == null) { throw new Exception("Invalid Id"); } return(_pRepo.GetPlayersByTeamId(id)); }