Revert "s/.done(/.then(/ since modern es6 track unhandled promise exceptions"
This reverts commit 09a8fec2
This commit is contained in:
parent
09a8fec261
commit
168b1b68bb
43 changed files with 72 additions and 74 deletions
|
@ -105,7 +105,7 @@ module.exports = createReactClass({
|
|||
phase: PHASE_SENDING_EMAIL,
|
||||
});
|
||||
this.reset = new PasswordReset(this.props.serverConfig.hsUrl, this.props.serverConfig.isUrl);
|
||||
this.reset.resetPassword(email, password).then(() => {
|
||||
this.reset.resetPassword(email, password).done(() => {
|
||||
this.setState({
|
||||
phase: PHASE_EMAIL_SENT,
|
||||
});
|
||||
|
|
|
@ -253,7 +253,7 @@ module.exports = createReactClass({
|
|||
this.setState({
|
||||
busy: false,
|
||||
});
|
||||
}).then();
|
||||
}).done();
|
||||
},
|
||||
|
||||
onUsernameChanged: function(username) {
|
||||
|
@ -424,7 +424,7 @@ module.exports = createReactClass({
|
|||
this.setState({
|
||||
busy: false,
|
||||
});
|
||||
}).then();
|
||||
}).done();
|
||||
},
|
||||
|
||||
_isSupportedFlow: function(flow) {
|
||||
|
|
|
@ -43,7 +43,7 @@ module.exports = createReactClass({
|
|||
const cli = MatrixClientPeg.get();
|
||||
this.setState({busy: true});
|
||||
const self = this;
|
||||
cli.getProfileInfo(cli.credentials.userId).then(function(result) {
|
||||
cli.getProfileInfo(cli.credentials.userId).done(function(result) {
|
||||
self.setState({
|
||||
avatarUrl: MatrixClientPeg.get().mxcUrlToHttp(result.avatar_url),
|
||||
busy: false,
|
||||
|
|
|
@ -371,7 +371,7 @@ module.exports = createReactClass({
|
|||
if (pushers[i].kind === 'email') {
|
||||
const emailPusher = pushers[i];
|
||||
emailPusher.data = { brand: this.props.brand };
|
||||
matrixClient.setPusher(emailPusher).then(() => {
|
||||
matrixClient.setPusher(emailPusher).done(() => {
|
||||
console.log("Set email branding to " + this.props.brand);
|
||||
}, (error) => {
|
||||
console.error("Couldn't set email branding: " + error);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue