From 12dd7a72323bf82d60e99502104e375864c0fbab Mon Sep 17 00:00:00 2001 From: Esteban MIno Date: Fri, 3 Aug 2018 18:01:40 -0400 Subject: [PATCH] popup initializing with suggested tokens --- ui/app/components/pages/home.js | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/ui/app/components/pages/home.js b/ui/app/components/pages/home.js index 97aaedd37..3b0a34f97 100644 --- a/ui/app/components/pages/home.js +++ b/ui/app/components/pages/home.js @@ -34,16 +34,12 @@ class Home extends Component { componentDidMount () { const { history, - unapprovedTxs = {}, - unapprovedMsgCount = 0, - unapprovedPersonalMsgCount = 0, - unapprovedTypedMessagesCount = 0, suggestedTokens = {}, unconfirmedTransactionsCount = 0, } = this.props // suggested new tokens - if (suggestedTokens.length > 0) { + if (Object.keys(suggestedTokens).length > 0) { history.push(CONFIRM_ADD_TOKEN_ROUTE) } @@ -238,7 +234,7 @@ function mapStateToProps (state) { isRevealingSeedWords: state.metamask.isRevealingSeedWords, Qr: state.appState.Qr, welcomeScreenSeen: state.metamask.welcomeScreenSeen, - + suggestedTokens: state.metamask.suggestedTokens, // state needed to get account dropdown temporarily rendering from app bar selected, unconfirmedTransactionsCount: unconfirmedTransactionsCountSelector(state),