Merge branch 't3chguy/remove_bluebird_2' of https://github.com/matrix-org/matrix-react-sdk into t3chguy/remove_bluebird

 Conflicts:
	src/components/views/right_panel/UserInfo.js
This commit is contained in:
Michael Telatynski 2019-11-18 10:36:43 +00:00
commit 5c172a383d
23 changed files with 864 additions and 463 deletions

View file

@ -550,7 +550,16 @@ module.exports = createReactClass({
danger: true,
onFinished: (accepted) => {
if (!accepted) return;
this.context.matrixClient.deactivateSynapseUser(this.props.member.userId);
this.context.matrixClient.deactivateSynapseUser(this.props.member.userId).catch(e => {
console.error("Failed to deactivate user");
console.error(e);
const ErrorDialog = sdk.getComponent("dialogs.ErrorDialog");
Modal.createTrackedDialog('Failed to deactivate Synapse user', '', ErrorDialog, {
title: _t('Failed to deactivate user'),
description: ((e && e.message) ? e.message : _t("Operation failed")),
});
});
},
});
},