You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A { a: undefined }
B {}
patch = diff(A,B) (results in 'remove a')
patchInPlace(patch, A)
fails with "path does not exist"
// key must exist for remove
if(notFound(pointer) || pointer.target[pointer.key] === void 0) {
throw new InvalidPatchOperationError('path does not exist ' + change.path);
}
The cause is the check for pointer.target[pointer.key] not being undefined.
The key needs to be present, but if the value is undefined that shouldn't prevent a removal.