Fix NullRef in Cloudflare detection service

pull/1056/head
Qstick 2 years ago
parent 4dee1d65d1
commit 8b8d0b24ae

@ -32,8 +32,8 @@ namespace NzbDrone.Core.Http.CloudFlare
}
// detect Custom CloudFlare for EbookParadijs, Film-Paleis, MuziekFabriek and Puur-Hollands
if (response.Headers.Vary.ToString() == "Accept-Encoding,User-Agent" &&
response.Headers.ContentEncoding.ToString() == "" &&
if (response.Headers.Vary == "Accept-Encoding,User-Agent" &&
response.Headers.ContentEncoding == "" &&
response.Content.ToLower().Contains("ddos"))
{
return true;

@ -19,7 +19,6 @@ namespace NzbDrone.Core.IndexerProxies.FlareSolverr
{
public class FlareSolverr : HttpIndexerProxyBase<FlareSolverrSettings>
{
private static readonly HashSet<string> CloudflareServerNames = new HashSet<string> { "cloudflare", "cloudflare-nginx", "ddos-guard" };
private readonly ICached<string> _cache;
public FlareSolverr(IProwlarrCloudRequestBuilder cloudRequestBuilder, IHttpClient httpClient, Logger logger, ILocalizationService localizationService, ICacheManager cacheManager)

Loading…
Cancel
Save