1
0
Fork 0
mirror of https://github.com/Jackett/Jackett synced 2025-01-04 06:22:45 +00:00

horriblesubs: keep cloudflare cookie (#8674)

This commit is contained in:
Diego Heras 2020-05-16 01:36:20 +02:00 committed by GitHub
parent 0b94c0fc8f
commit 7b9aea89cb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -72,7 +72,7 @@ namespace Jackett.Common.Indexers
}; };
var searchUrl = ApiEndpoint + "?" + queryCollection.GetQueryString(); var searchUrl = ApiEndpoint + "?" + queryCollection.GetQueryString();
var response = await RequestStringWithCookiesAndRetry(searchUrl, string.Empty); var response = await RequestStringWithCookiesAndRetry(searchUrl);
try try
{ {
@ -112,7 +112,7 @@ namespace Jackett.Common.Indexers
}; };
var searchUrl = ApiEndpoint + "?" + queryCollection.GetQueryString(); var searchUrl = ApiEndpoint + "?" + queryCollection.GetQueryString();
var response = await RequestStringWithCookiesAndRetry(searchUrl, string.Empty); var response = await RequestStringWithCookiesAndRetry(searchUrl);
try try
{ {
@ -146,7 +146,7 @@ namespace Jackett.Common.Indexers
var releases = new List<ReleaseInfo>(); var releases = new List<ReleaseInfo>();
var parser = new HtmlParser(); var parser = new HtmlParser();
var response = await RequestStringWithCookiesAndRetry(resultUrl, string.Empty); var response = await RequestStringWithCookiesAndRetry(resultUrl);
await FollowIfRedirect(response); await FollowIfRedirect(response);
try try
@ -168,7 +168,7 @@ namespace Jackett.Common.Indexers
var nextId = 0; var nextId = 0;
while (true) while (true)
{ {
var showApiResponse = await RequestStringWithCookiesAndRetry(apiUrl + "&nextid=" + nextId, string.Empty); var showApiResponse = await RequestStringWithCookiesAndRetry(apiUrl + "&nextid=" + nextId);
var showApiDom = parser.ParseDocument(showApiResponse.Content); var showApiDom = parser.ParseDocument(showApiResponse.Content);
var releaseRowResults = showApiDom.QuerySelectorAll("div.rls-info-container"); var releaseRowResults = showApiDom.QuerySelectorAll("div.rls-info-container");
rows.AddRange(releaseRowResults); rows.AddRange(releaseRowResults);