Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent showing connected accounts without origin #8891

Conversation

Gudahtt
Copy link
Member

@Gudahtt Gudahtt commented Jul 2, 2020

There was a case where the activeTab.origin was not set, yet the user could still navigate to the "Connected accounts" modal, which assumes that activeTab.origin is set. This would happen in Firefox when the user opened the popup on a page internal to Firefox (e.g. about:blank). The connected status indicator would still be shown, but the UI would crash when it was clicked.

The connected status indicator is now hidden whenever activeTab.origin is falsy. The 'Unconnected account' alert has also
been made impossible to trigger in that circumstance.

@Gudahtt
Copy link
Member Author

Gudahtt commented Jul 2, 2020

Depends upon #8890 #8890 is now merged.

@metamaskbot
Copy link
Collaborator

Builds ready [42c61de]
Page Load Metrics (646 ± 55 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint32125593014
domContentLoaded37281564411455
load37482264611555
domInteractive37281564411455

Base automatically changed from set-empty-active-tab-if-no-valid-origin to develop July 2, 2020 21:01
There was a case where the `activeTab.origin` was not set, yet the user
could still navigate to the "Connected accounts" modal, which assumes
that `activeTab.origin` is set. This would happen in Firefox when the
user opened the popup on a page internal to Firefox (e.g.
`about:blank`). The connected status indicator would still be shown,
but the UI would crash when it was clicked.

The connected status indicator is now hidden whenever
`activeTab.origin` is falsy. The 'Unconnected account' alert has also
been made impossible to trigger in that circumstance.
@Gudahtt Gudahtt force-pushed the prevent-showing-connected-accounts-when-no-active-tab-origin-is-set branch from 42c61de to c46e6a4 Compare July 2, 2020 21:01
@Gudahtt Gudahtt marked this pull request as ready for review July 2, 2020 21:01
@Gudahtt Gudahtt requested a review from a team as a code owner July 2, 2020 21:01
Copy link
Contributor

@whymarrh whymarrh left a comment

Choose a reason for hiding this comment

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

LGTM!

@metamaskbot
Copy link
Collaborator

Builds ready [c46e6a4]
Page Load Metrics (906 ± 52 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaintNaNNaNNaNNaNNaN
domContentLoaded600105590410952
load602105790610952
domInteractive600105490410952

@Gudahtt Gudahtt merged commit d9a27fc into develop Jul 2, 2020
@Gudahtt Gudahtt deleted the prevent-showing-connected-accounts-when-no-active-tab-origin-is-set branch July 2, 2020 21:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants