mirror of
https://github.com/Prowlarr/Prowlarr
synced 2026-05-08 12:43:19 +02:00
Fixed: Allow redirect and set referer for Anthelion
This commit is contained in:
parent
80ec66514e
commit
8e597c8179
1 changed files with 9 additions and 1 deletions
|
|
@ -52,7 +52,8 @@ protected override async Task DoLogin()
|
|||
{
|
||||
var requestBuilder = new HttpRequestBuilder(LoginUrl)
|
||||
{
|
||||
LogResponseContent = true
|
||||
LogResponseContent = true,
|
||||
AllowAutoRedirect = true
|
||||
};
|
||||
|
||||
requestBuilder.Method = HttpMethod.POST;
|
||||
|
|
@ -69,6 +70,13 @@ protected override async Task DoLogin()
|
|||
.SetHeader("Content-Type", "multipart/form-data")
|
||||
.Build();
|
||||
|
||||
var headers = new NameValueCollection
|
||||
{
|
||||
{ "Referer", LoginUrl }
|
||||
};
|
||||
|
||||
authLoginRequest.Headers.Add(headers);
|
||||
|
||||
var response = await ExecuteAuth(authLoginRequest);
|
||||
|
||||
if (!response.Content.Contains("logout.php"))
|
||||
|
|
|
|||
Loading…
Reference in a new issue