mirror of
https://github.com/element-hq/element-web
synced 2024-11-24 10:15:43 +03:00
Simpler code
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
This commit is contained in:
parent
6401577fe4
commit
27db0da437
1 changed files with 1 additions and 11 deletions
|
@ -834,17 +834,7 @@ export default class RoomView extends React.Component<IProps, IState> {
|
|||
|
||||
case Action.FocusAComposer: {
|
||||
// re-dispatch to the correct composer
|
||||
if (this.state.editState) {
|
||||
dis.dispatch({
|
||||
...payload,
|
||||
action: Action.FocusEditMessageComposer,
|
||||
});
|
||||
} else {
|
||||
dis.dispatch({
|
||||
...payload,
|
||||
action: Action.FocusSendMessageComposer,
|
||||
});
|
||||
}
|
||||
dis.fire(this.state.editState ? Action.FocusEditMessageComposer : Action.FocusSendMessageComposer);
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue