We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 517a819 + 6f98adb commit 5f0b560Copy full SHA for 5f0b560
src/lib/src/json-schema-form.service.ts
@@ -466,9 +466,7 @@ export class JsonSchemaFormService {
466
return Object.keys(errors)
467
// Hide 'required' error, unless it is the only one
468
.filter(errorKey => errorKey !== 'required' || Object.keys(errors).length === 1)
469
- .map(errorKey =>
470
- // If custom error message is a function, return result
471
- typeof errorMessages[errorKey] === 'function' ?
+ .map(errorKey => typeof errorMessages[errorKey] === 'function' ? // If custom error message is a function, return result
472
errorMessages[errorKey](errors[errorKey]) :
473
// If custom error message is a string, replace placeholders and return
474
typeof errorMessages[errorKey] === 'string' ?
0 commit comments