2018-11-23 07:03:32 +00:00
|
|
|
using NzbDrone.Core.Download;
|
|
|
|
|
2019-12-03 01:36:18 +00:00
|
|
|
namespace Radarr.Api.V3.DownloadClient
|
2018-11-23 07:03:32 +00:00
|
|
|
{
|
|
|
|
public class DownloadClientModule : ProviderModuleBase<DownloadClientResource, IDownloadClient, DownloadClientDefinition>
|
|
|
|
{
|
|
|
|
public static readonly DownloadClientResourceMapper ResourceMapper = new DownloadClientResourceMapper();
|
|
|
|
|
|
|
|
public DownloadClientModule(IDownloadClientFactory downloadClientFactory)
|
|
|
|
: base(downloadClientFactory, "downloadclient", ResourceMapper)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
protected override void Validate(DownloadClientDefinition definition, bool includeWarnings)
|
|
|
|
{
|
2019-12-22 22:08:53 +00:00
|
|
|
if (!definition.Enable)
|
|
|
|
{
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
2018-11-23 07:03:32 +00:00
|
|
|
base.Validate(definition, includeWarnings);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|