Send the correct UIA alongside the wrong UIA for backwards comaptibility
Fixes https://github.com/vector-im/riot-web/issues/10312
This commit is contained in:
parent
0950037ca3
commit
862fb16120
2 changed files with 19 additions and 0 deletions
|
@ -91,7 +91,13 @@ export const PasswordAuthEntry = React.createClass({
|
||||||
|
|
||||||
this.props.submitAuthDict({
|
this.props.submitAuthDict({
|
||||||
type: PasswordAuthEntry.LOGIN_TYPE,
|
type: PasswordAuthEntry.LOGIN_TYPE,
|
||||||
|
// TODO: Remove `user` once servers support proper UIA
|
||||||
|
// See https://github.com/vector-im/riot-web/issues/10312
|
||||||
user: this.props.matrixClient.credentials.userId,
|
user: this.props.matrixClient.credentials.userId,
|
||||||
|
identifier: {
|
||||||
|
type: "m.id.user",
|
||||||
|
user: this.props.matrixClient.getUserId(),
|
||||||
|
},
|
||||||
password: this.state.password,
|
password: this.state.password,
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -463,11 +469,18 @@ export const MsisdnAuthEntry = React.createClass({
|
||||||
);
|
);
|
||||||
this.props.submitAuthDict({
|
this.props.submitAuthDict({
|
||||||
type: MsisdnAuthEntry.LOGIN_TYPE,
|
type: MsisdnAuthEntry.LOGIN_TYPE,
|
||||||
|
// TODO: Remove `threepid_creds` once servers support proper UIA
|
||||||
|
// See https://github.com/vector-im/riot-web/issues/10312
|
||||||
threepid_creds: {
|
threepid_creds: {
|
||||||
sid: this._sid,
|
sid: this._sid,
|
||||||
client_secret: this.props.clientSecret,
|
client_secret: this.props.clientSecret,
|
||||||
id_server: idServerParsedUrl.host,
|
id_server: idServerParsedUrl.host,
|
||||||
},
|
},
|
||||||
|
threepidCreds: {
|
||||||
|
sid: this._sid,
|
||||||
|
client_secret: this.props.clientSecret,
|
||||||
|
id_server: idServerParsedUrl.host,
|
||||||
|
},
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
this.setState({
|
this.setState({
|
||||||
|
|
|
@ -63,7 +63,13 @@ export default class DeactivateAccountDialog extends React.Component {
|
||||||
// for this endpoint. In reality it could be any UI auth.
|
// for this endpoint. In reality it could be any UI auth.
|
||||||
const auth = {
|
const auth = {
|
||||||
type: 'm.login.password',
|
type: 'm.login.password',
|
||||||
|
// TODO: Remove `user` once servers support proper UIA
|
||||||
|
// See https://github.com/vector-im/riot-web/issues/10312
|
||||||
user: MatrixClientPeg.get().credentials.userId,
|
user: MatrixClientPeg.get().credentials.userId,
|
||||||
|
identifier: {
|
||||||
|
type: "m.id.user",
|
||||||
|
user: MatrixClientPeg.get().credentials.userId,
|
||||||
|
},
|
||||||
password: this.state.password,
|
password: this.state.password,
|
||||||
};
|
};
|
||||||
await MatrixClientPeg.get().deactivateAccount(auth, this.state.shouldErase);
|
await MatrixClientPeg.get().deactivateAccount(auth, this.state.shouldErase);
|
||||||
|
|
Loading…
Reference in a new issue