Skip to content

Commit a9b9f60

Browse files
Fixed propertyPath for deeply nested required fields
1 parent 2d0a4c6 commit a9b9f60

File tree

1 file changed

+1
-1
lines changed
  • src/vfjs-global-mixin/methods/vfjs-validation

1 file changed

+1
-1
lines changed

src/vfjs-global-mixin/methods/vfjs-validation/getters.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const vfjsValidationGetters = {
1818
if (error.keyword === 'required') {
1919
if (error.params && error.params.missingProperty) {
2020
const key = error.params.missingProperty;
21-
const parent = String(error.dataPath).substr(1);
21+
const parent = String(error.dataPath).substr(1).replace(/\//g, '.');
2222
const propertyPath = parent ? `${parent}.${key}` : key;
2323

2424
if (required.indexOf(propertyPath) === -1) {

0 commit comments

Comments
 (0)