|
|
|
@ -1,4 +1,5 @@
|
|
|
|
|
using FluentValidation.Validators;
|
|
|
|
|
using FluentValidation.Validators;
|
|
|
|
|
using NzbDrone.Common.Disk;
|
|
|
|
|
using NzbDrone.Common.Extensions;
|
|
|
|
|
using NzbDrone.Core.RootFolders;
|
|
|
|
|
|
|
|
|
@ -24,7 +25,7 @@ namespace NzbDrone.Core.Validation.Paths
|
|
|
|
|
|
|
|
|
|
context.MessageFormatter.AppendArgument("path", context.PropertyValue.ToString());
|
|
|
|
|
|
|
|
|
|
return !_rootFolderService.All().Exists(r => r.Path.PathEquals(context.PropertyValue.ToString()));
|
|
|
|
|
return !_rootFolderService.All().Exists(r => r.Path.IsPathValid(PathValidationType.CurrentOs) && r.Path.PathEquals(context.PropertyValue.ToString()));
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|