GGN API: Fix empty result (#14352), resolves #13544

This commit is contained in:
Webster 2023-05-20 11:05:02 +02:00 committed by GitHub
parent a5331e20c2
commit 558d3530fa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 0 deletions

View File

@ -240,6 +240,11 @@ namespace Jackett.Common.Indexers
{
var group = gObj.Value as JObject;
if (group["Torrents"].Type == JTokenType.Array && group["Torrents"] is JArray array && array.Count == 0)
{
continue;
}
foreach (var tObj in JObject.FromObject(group["Torrents"]))
{
var torrent = tObj.Value as JObject;