1
0
Fork 0
mirror of https://github.com/Jackett/Jackett synced 2025-02-22 06:10:49 +00:00

scenetime: fix query without results. resolves #8549 (#8569)

This commit is contained in:
Diego Heras 2020-05-09 15:41:35 +02:00 committed by GitHub
parent a5d4056e50
commit 8e48d4b1dc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -187,15 +187,18 @@ namespace Jackett.Common.Indexers
qParams.Add("freeleech", "on");
var searchUrl = SearchUrl + "?" + qParams.GetQueryString();
var results = await RequestStringWithCookies(searchUrl);
// response without results (the message is misleading)
if (results.Content?.Contains("slow down geek!!!") == true)
return new List<ReleaseInfo>();
// not logged in
if (results.Content == null || !results.Content.Contains("/logout.php"))
throw new Exception("The user is not logged in. It is possible that the cookie has expired or you " +
"made a mistake when copying it. Please check the settings.");
var releases = ParseResponse(query, results.Content);
return releases;
return ParseResponse(query, results.Content);
}
private List<ReleaseInfo> ParseResponse(TorznabQuery query, string htmlResponse)