mirror of
https://github.com/element-hq/element-web
synced 2024-11-28 12:28:50 +03:00
remove commented code and move modal.close into a finally block
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
parent
9dd2184b33
commit
4e216714b5
2 changed files with 3 additions and 3 deletions
|
@ -58,14 +58,15 @@ export default class GroupInviteTileContextMenu extends React.Component {
|
||||||
try {
|
try {
|
||||||
await GroupStore.leaveGroup(this.props.group.groupId);
|
await GroupStore.leaveGroup(this.props.group.groupId);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
console.error(e);
|
console.error("Error rejecting community invite: ", e);
|
||||||
const ErrorDialog = sdk.getComponent("dialogs.ErrorDialog");
|
const ErrorDialog = sdk.getComponent("dialogs.ErrorDialog");
|
||||||
Modal.createTrackedDialog('Error rejecting invite', '', ErrorDialog, {
|
Modal.createTrackedDialog('Error rejecting invite', '', ErrorDialog, {
|
||||||
title: _t("Error"),
|
title: _t("Error"),
|
||||||
description: _t("Unable to reject invite"),
|
description: _t("Unable to reject invite"),
|
||||||
});
|
});
|
||||||
|
} finally {
|
||||||
|
modal.close();
|
||||||
}
|
}
|
||||||
modal.close();
|
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -94,7 +94,6 @@ export default React.createClass({
|
||||||
group: this.props.group,
|
group: this.props.group,
|
||||||
onFinished: () => {
|
onFinished: () => {
|
||||||
this.setState({ menuDisplayed: false });
|
this.setState({ menuDisplayed: false });
|
||||||
// this.props.refreshSubList();
|
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
this.setState({ menuDisplayed: true });
|
this.setState({ menuDisplayed: true });
|
||||||
|
|
Loading…
Reference in a new issue