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

Disconnect from IS Button#3305

Merged
dbkr merged 13 commits intodevelopfrom
dbkr/disco_is
Aug 14, 2019
Merged

Disconnect from IS Button#3305
dbkr merged 13 commits intodevelopfrom
dbkr/disco_is

Conversation

@dbkr
Copy link
Member

@dbkr dbkr commented Aug 12, 2019

@dbkr dbkr requested a review from a team August 12, 2019 13:43
@turt2live turt2live requested review from turt2live and removed request for a team August 12, 2019 17:55
Copy link
Member

@turt2live turt2live left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

largely looks fine based on dbkr/change_is...dbkr/disco_is

It looks like there's some merge conflicts, but I think they are easily solved here.

_disconnectIdServer = () => {
MatrixClientPeg.get().setIdentityServerUrl(null);
localStorage.removeItem("mx_is_access_token");
localStorage.removeItem("mx_is_url");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I kinda wonder if these 3 things should happen in the Lifecycle? It feels a bit dirty to manipulate the settings here.

This is probably fine though.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, probably, but since it's currently only used here I'd probably argue for moving it into a function in lifecycle if we ever use it anywhere else.

Copy link
Collaborator

@jryans jryans left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think an important step of warning about live bindings is missing here, so if this will be merged as fixing element-hq/element-web#10425, then we should break that extra bit out as a separate issue.

});
};

_onDisconnectClicked = () => {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure that this dialog is really adding that much, since it just confirms removing the server, and we're already making the first button appear dangerous... I wonder if @nadonomy has an opinion.

I think we do want some kind of step that warns about disconnecting the IS when there are 3PIDs currrently bound, as mentioned in the issue.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Trying it with no confirmation felt very trigger-happy - I might even argue that for establishing the convention that any danger button has a confirmation.

dbkr and others added 7 commits August 14, 2019 10:03
Co-Authored-By: Travis Ralston <travpc@gmail.com>
Co-Authored-By: J. Ryan Stinnett <jryans@gmail.com>
Co-Authored-By: J. Ryan Stinnett <jryans@gmail.com>
Co-Authored-By: J. Ryan Stinnett <jryans@gmail.com>
@dbkr
Copy link
Member Author

dbkr commented Aug 14, 2019

binding warning split out to element-hq/element-web#10550

@dbkr dbkr merged commit 30681c7 into develop Aug 14, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Ability to disconnect from the identity server by pressing buttons in user settings.

3 participants