aboutsummaryrefslogtreecommitdiffstats
path: root/ui
diff options
context:
space:
mode:
authorDan <danjm.com@gmail.com>2017-10-27 01:15:05 +0800
committerChi Kei Chan <chikeichan@gmail.com>2017-10-27 03:27:09 +0800
commit0ed1add110ec630ed358aa44af030623bab1ad92 (patch)
tree1e3688180e2a47e1fe1deaf6ab288854c6aa106b /ui
parentf9fc6cec3b01357dd5bb182b6389426d1f17260a (diff)
downloadtangerine-wallet-browser-0ed1add110ec630ed358aa44af030623bab1ad92.tar.gz
tangerine-wallet-browser-0ed1add110ec630ed358aa44af030623bab1ad92.tar.zst
tangerine-wallet-browser-0ed1add110ec630ed358aa44af030623bab1ad92.zip
Clear import error state on logout.
Diffstat (limited to 'ui')
-rw-r--r--ui/app/accounts/import/private-key.js4
-rw-r--r--ui/app/components/account-menu/index.js1
2 files changed, 5 insertions, 0 deletions
diff --git a/ui/app/accounts/import/private-key.js b/ui/app/accounts/import/private-key.js
index 68ccee58e..e214bcbbe 100644
--- a/ui/app/accounts/import/private-key.js
+++ b/ui/app/accounts/import/private-key.js
@@ -17,6 +17,10 @@ function PrivateKeyImportView () {
Component.call(this)
}
+PrivateKeyImportView.prototype.componentWillUnmount = function () {
+ this.props.dispatch(actions.displayWarning(null))
+}
+
PrivateKeyImportView.prototype.render = function () {
const { error } = this.props
diff --git a/ui/app/components/account-menu/index.js b/ui/app/components/account-menu/index.js
index 38c7bcb2d..a9f075ec7 100644
--- a/ui/app/components/account-menu/index.js
+++ b/ui/app/components/account-menu/index.js
@@ -32,6 +32,7 @@ function mapDispatchToProps (dispatch) {
},
lockMetamask: () => {
dispatch(actions.lockMetamask())
+ dispatch(actions.displayWarning(null))
dispatch(actions.toggleAccountMenu())
},
showConfigPage: () => {