Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Merge pull request #3398 from matrix-org/jryans/is-input-tweak
Browse files Browse the repository at this point in the history
Stop setting IS input field on account change
  • Loading branch information
jryans authored Sep 9, 2019
2 parents 1422b1d + 5fddb20 commit 24f1ec8
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions src/components/views/settings/SetIdServer.js
Original file line number Diff line number Diff line change
Expand Up @@ -93,18 +93,11 @@ export default class SetIdServer extends React.Component {

onAction = (payload) => {
// We react to changes in the ID server in the event the user is staring at this form
// when changing their identity server on another device. If the user is trying to change
// it in two places, we'll end up stomping all over their input, but at that point we
// should question our UX which led to them doing that.
// when changing their identity server on another device.
if (payload.action !== "id_server_changed") return;

const fullUrl = MatrixClientPeg.get().getIdentityServerUrl();
let abbr = '';
if (fullUrl) abbr = abbreviateUrl(fullUrl);

this.setState({
currentClientIdServer: fullUrl,
idServer: abbr,
currentClientIdServer: MatrixClientPeg.get().getIdentityServerUrl(),
});
};

Expand Down

0 comments on commit 24f1ec8

Please sign in to comment.