Fixed: Validation for nested settings not running

Prevents #1243
This commit is contained in:
Qstick
2022-12-18 23:20:46 -06:00
parent dfe132cda2
commit 57dcd861a9
8 changed files with 19 additions and 14 deletions
@@ -35,6 +35,7 @@ namespace NzbDrone.Core.Indexers.Newznab
public NewznabSettingsValidator()
{
RuleFor(x => x.BaseSettings).SetValidator(new IndexerCommonSettingsValidator());
RuleFor(c => c.BaseUrl).ValidRootUrl();
RuleFor(c => c.ApiPath).ValidUrlBase("/api");
RuleFor(c => c.ApiKey).NotEmpty().When(ShouldHaveApiKey);