Use custom validator message instead of the generic one. Fixes #3640
Merge pull request #3640 from jmnavarro/fix-3640

Custom validator always produce the same validation error message