mirror of
https://github.com/Jackett/Jackett
synced 2025-03-04 02:38:08 +00:00
parent
1ab7467621
commit
59f29abfc4
1 changed files with 2 additions and 1 deletions
|
@ -250,8 +250,9 @@ namespace Jackett.Common.Indexers.Definitions.Abstract
|
|||
var headers = apiKey != null ? new Dictionary<string, string> { [AuthorizationName] = string.Format(AuthorizationFormat, apiKey.Value) } : null;
|
||||
|
||||
var response = await RequestWithCookiesAndRetryAsync(searchUrl, headers: headers);
|
||||
|
||||
// we get a redirect in html pages and an error message in json response (api)
|
||||
if (response.IsRedirect && !useApiKey)
|
||||
if (response.IsRedirect && !useApiKey && configData.CookieItem.Value.IsNullOrWhiteSpace())
|
||||
{
|
||||
// re-login only if API key is not in use.
|
||||
await ApplyConfiguration(null);
|
||||
|
|
Loading…
Add table
Reference in a new issue