Lift 3PID state management up to Settings tab

This pulls the 3PID state management in Settings up to a single location so that
the Account and Discovery sections now work from a single list that updates
immediately.

Fixes https://github.com/vector-im/riot-web/issues/10519
This commit is contained in:
J. Ryan Stinnett 2019-09-11 11:33:58 +01:00
parent 1703913118
commit f04c347df7
7 changed files with 77 additions and 77 deletions

View file

@ -22,7 +22,7 @@ import sdk from '../../../index';
import MatrixClientPeg from "../../../MatrixClientPeg";
import Modal from '../../../Modal';
import dis from "../../../dispatcher";
import { getThreepidBindStatus } from '../../../boundThreepids';
import { getThreepidsWithBindStatus } from '../../../boundThreepids';
import IdentityAuthClient from "../../../IdentityAuthClient";
import {SERVICE_TYPES} from "matrix-js-sdk";
import {abbreviateUrl, unabbreviateUrl} from "../../../utils/UrlUtils";
@ -249,7 +249,7 @@ export default class SetIdServer extends React.Component {
};
async _showServerChangeWarning({ title, unboundMessage, button }) {
const threepids = await getThreepidBindStatus(MatrixClientPeg.get());
const threepids = await getThreepidsWithBindStatus(MatrixClientPeg.get());
const boundThreepids = threepids.filter(tp => tp.bound);
let message;