Skip to content

Commit

Permalink
fix: quit unsetting path if its already unset
Browse files Browse the repository at this point in the history
  • Loading branch information
logaretm committed Jul 6, 2021
1 parent 854cd47 commit cfe45ba
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/vee-validate/src/utils/common.ts
Expand Up @@ -101,7 +101,7 @@ export function unsetPath(object: NestedRecord, path: string): void {
}

// Key does not exist, exit
if (!(keys[i] in acc)) {
if (!(keys[i] in acc) || isNullOrUndefined(acc[keys[i]])) {
break;
}

Expand Down

0 comments on commit cfe45ba

Please sign in to comment.