Fix bug: Undo multi element (#1461)

* Add failing test

* Fix multi element undo

* Update snapshots
This commit is contained in:
Ed Bentley 2020-04-20 14:05:39 +01:00 committed by GitHub
parent b8a9ad208d
commit 9b7a743e8b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 145 additions and 39 deletions

View file

@ -266,7 +266,7 @@ class App extends React.Component<any, AppState> {
}
this.setState((state) => ({
...res.appState,
editingElement: editingElement || state.editingElement,
editingElement: editingElement || res.appState?.editingElement || null,
isCollaborating: state.isCollaborating,
collaborators: state.collaborators,
}));