public IEnumerable<Team> GetBySeasonCompetition(SeasonCompetition seasonCompetition) { using (var teamRepository = new RepositoryFactory().CreateTeamRepository()) { var teams = teamRepository.GetTeamsBySeasonCompetition(seasonCompetition); return teams; } }