mirror of
https://github.com/vector-im/element-web.git
synced 2024-11-17 05:55:00 +08:00
Make some dispatches async
It looks like these dispatches were being dispatched while already dispatching, causing soft crashes (although I can't see where the first dispatch was from). Either way, seems like these didn't need to be sync.
This commit is contained in:
parent
9ac5f4d2ee
commit
67e2ae9988
@ -240,10 +240,10 @@ class LoggedInView extends React.Component<IProps, IState> {
|
||||
onCollapsed: (_collapsed) => {
|
||||
collapsed = _collapsed;
|
||||
if (_collapsed) {
|
||||
dis.dispatch({action: "hide_left_panel"}, true);
|
||||
dis.dispatch({action: "hide_left_panel"});
|
||||
window.localStorage.setItem("mx_lhs_size", '0');
|
||||
} else {
|
||||
dis.dispatch({action: "show_left_panel"}, true);
|
||||
dis.dispatch({action: "show_left_panel"});
|
||||
}
|
||||
},
|
||||
onResized: (_size) => {
|
||||
|
Loading…
Reference in New Issue
Block a user