Skip to content

Commit

Permalink
check for undefined when setting modified properties
Browse files Browse the repository at this point in the history
  • Loading branch information
keianhzo committed Oct 19, 2021
1 parent 5654178 commit dcac17b
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/editor/nodes/EditorNodeMixin.js
Original file line number Diff line number Diff line change
Expand Up @@ -467,10 +467,12 @@ export default function EditorNodeMixin(Object3DClass) {
}

set modifiedProperties(object) {
const keys = Object.keys(object);
keys.forEach(key => {
this._modifiedProperties[key] = { ...this._modifiedProperties[key], ...object[key] };
});
if (object) {
const keys = Object.keys(object);
keys.forEach(key => {
this._modifiedProperties[key] = { ...this._modifiedProperties[key], ...object[key] };
});
}
}

get modifiedProperties() {
Expand Down

0 comments on commit dcac17b

Please sign in to comment.