Fixes: U4-3806 Prevalue validation run all field validators against all fields

This commit is contained in:
perploug
2013-12-06 10:07:04 +01:00
parent 82ec2d28ef
commit b03427cabc

View File

@@ -86,8 +86,8 @@ namespace Umbraco.Web.Editors
foreach (var preVal in dataType.PreValues)
{
var postedValue = preVal.Value;
foreach (var v in propertyEditor.PreValueEditor.Fields.SelectMany(x => x.Validators))
foreach (var v in propertyEditor.PreValueEditor.Fields.Where(x => x.Key == preVal.Key).SelectMany(x => x.Validators))
{
foreach (var result in v.Validate(postedValue, null, propertyEditor))
{