Misc Fixes

This commit is contained in:
Qstick
2021-02-19 22:29:47 -05:00
parent b3990d647c
commit 0afb01962f
21 changed files with 79 additions and 89 deletions
@@ -16,7 +16,7 @@ namespace NzbDrone.Core.Indexers.Newznab
private readonly INewznabCapabilitiesProvider _capabilitiesProvider;
public override string Name => "Newznab";
public override string BaseUrl => Settings.BaseUrl;
public override string BaseUrl => GetBaseUrlFromSettings();
public override bool FollowRedirect => true;
public override DownloadProtocol Protocol => DownloadProtocol.Usenet;
@@ -40,6 +40,18 @@ namespace NzbDrone.Core.Indexers.Newznab
return new NewznabRssParser(Settings);
}
public string GetBaseUrlFromSettings()
{
var baseUrl = "";
if (Definition == null || Settings == null || Settings.Categories == null)
{
return baseUrl;
}
return Settings.BaseUrl;
}
public IndexerCapabilities GetCapabilitiesFromSettings()
{
var caps = new IndexerCapabilities();