mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Fixing persisting error message from MobileSyncPage (#11835)
This commit is contained in:
parent
d1e264446d
commit
1837397202
@ -28,6 +28,7 @@ export default class MobileSyncPage extends Component {
|
||||
requestRevealSeedWords: PropTypes.func.isRequired,
|
||||
exportAccounts: PropTypes.func.isRequired,
|
||||
keyrings: PropTypes.array,
|
||||
hideWarning: PropTypes.func.isRequired,
|
||||
};
|
||||
|
||||
state = {
|
||||
@ -277,6 +278,9 @@ export default class MobileSyncPage extends Component {
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
if (this.state.error) {
|
||||
this.props.hideWarning();
|
||||
}
|
||||
this.clearTimeouts();
|
||||
this.disconnectWebsockets();
|
||||
}
|
||||
|
@ -4,6 +4,7 @@ import {
|
||||
requestRevealSeedWords,
|
||||
fetchInfoToSync,
|
||||
exportAccounts,
|
||||
hideWarning,
|
||||
} from '../../store/actions';
|
||||
import { getMostRecentOverviewPage } from '../../ducks/history/history';
|
||||
import { getMetaMaskKeyrings } from '../../selectors';
|
||||
@ -17,6 +18,7 @@ const mapDispatchToProps = (dispatch) => {
|
||||
displayWarning: (message) => dispatch(displayWarning(message || null)),
|
||||
exportAccounts: (password, addresses) =>
|
||||
dispatch(exportAccounts(password, addresses)),
|
||||
hideWarning: () => dispatch(hideWarning()),
|
||||
};
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user