Fix search not returning data

This commit is contained in:
2015-11-02 23:05:36 +01:00
parent 3ea423c87e
commit 2f82bd96c6
+5 -2
View File
@@ -24,8 +24,11 @@ namespace MusicPlayer
{
// Q artist genre album
JObject o = nw.SendString($"search?q={search}&album={album}&genre={genre}&artist={artist}");
Console.WriteLine(o.PropertyValues().ToString());
if (o["result"].ToString() == "OK") { return o; }
if (o != null)
{
Console.WriteLine(o.PropertyValues().ToString());
if (o["result"].ToString() == "OK") { return o; }
}
return null;
}