no idea, and improvements to logging

This commit is contained in:
Master Kwoth
2016-02-18 03:29:30 +01:00
parent e2d6d8aebf
commit 4404150693
2 changed files with 45 additions and 27 deletions

View File

@ -74,7 +74,7 @@ namespace NadekoBot.Classes.Music {
if (OnResolving != null)
OnResolving();
var links = await SearchHelper.FindYoutubeUrlByKeywords(Query);
var allVideos = await YouTube.Default.GetAllVideosAsync(links);
var allVideos = await Task.Factory.StartNew(async () => await YouTube.Default.GetAllVideosAsync(links)).Unwrap();
var videos = allVideos.Where(v => v.AdaptiveKind == AdaptiveKind.Audio);
var video = videos
.Where(v => v.AudioBitrate < 192)