public async Task <Song[]> RunAsync() { SetConnection(); var searchListRequest = YoutubeService.Search.List("snippet"); searchListRequest.Q = Genre; searchListRequest.MaxResults = SongsQuantity; var searchListResponse = await searchListRequest.ExecuteAsync(); return(_musicConverter.Convert(searchListResponse)); }
public MusicBO Add(MusicBO music) { using (var uow = facade.UnitOfWork) { var newMusic = uow.MusicRepository.Add(conv.Convert(music)); uow.Complete(); return(conv.Convert(newMusic)); } }