Handle the case where customErrorMessageSet is true.

pull/4097/head
maliming 5 years ago
parent 9b2d8fca89
commit 427d9a5604

@ -20,13 +20,12 @@ namespace Volo.Abp.AspNetCore.Mvc.Validation
{
validationAttribute.ErrorMessage =
"The field {0} must be a string with a minimum length of {2} and a maximum length of {1}.";
return;
}
}
else
{
validationAttribute.ErrorMessage =
ValidationAttributeErrorMessageStringProperty.GetValue(validationAttribute) as string;
}
validationAttribute.ErrorMessage =
ValidationAttributeErrorMessageStringProperty.GetValue(validationAttribute) as string;
}
}
}

Loading…
Cancel
Save