public List<PlaylistDto> GetUploadsPlaylist(IEnumerable<string> ids) { var playlists = new List<PlaylistDto>(); foreach (var playlist in ids .Select(id => new PlaylistsQuery { Id = id }) .Select(query => _playlistQueryHandler.GetUploadsPlaylist(query))) { playlists.AddPlaylists(new[] {playlist}); } return playlists; }
public List<PlaylistDto> GetPlaylists(IEnumerable<string> channelIds) { var playlists = new List<PlaylistDto>(); foreach (var playlist in channelIds .Select(channelId => new PlaylistsQuery { Id = channelId }) .Select(query => _playlistQueryHandler.GetAllPlaylists(query))) { playlists.AddPlaylists(playlist); } return playlists; }