chore: reword attr err msg + add help link
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
surtur 2021-01-26 14:57:41 +01:00
parent 7644066138
commit 9e90f3ee28
Signed by: wanderer
GPG Key ID: 19CE1EC1D9E0486D

View File

@ -28,7 +28,7 @@ namespace pwt_0x01_ng.Models.Validation
throw new NotImplementedException($"Attribute {nameof(FileTypeAttr)} not implemented for object {value.GetType()}.");
}
protected string GetErrorMessage(string member_name) => $"make sure the {member_name} you picked really is an image ({type}/*).";
protected string GetErrorMessage(string member_name) => $"make sure the {member_name} you picked really is of type <code>{type}/*</code>. <a href=\"https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types\" title=\"help\" target=\"_blank\" rel=\"noopener noreferer\"><em>help</em></a>";
public void AddValidation(ClientModelValidationContext ctx){
MergeAttribute(ctx.Attributes, "data-val", "true");