From 050aa72ea89f615597c4ac6166fcab707f0d5714 Mon Sep 17 00:00:00 2001 From: pbca26 Date: Wed, 21 Feb 2018 20:15:06 +0300 Subject: [PATCH] elections history render fix --- .../notaryElectionsModal/notaryElectionsModal.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/react/src/components/dashboard/notaryElectionsModal/notaryElectionsModal.js b/react/src/components/dashboard/notaryElectionsModal/notaryElectionsModal.js index 4e73f50..d7b0254 100755 --- a/react/src/components/dashboard/notaryElectionsModal/notaryElectionsModal.js +++ b/react/src/components/dashboard/notaryElectionsModal/notaryElectionsModal.js @@ -383,6 +383,7 @@ class NotaryElectionsModal extends React.Component { isAuth: true, pub: res.result, }); + this.sync(); } else { Store.dispatch( triggerToaster( @@ -402,8 +403,6 @@ class NotaryElectionsModal extends React.Component { // reset login input vals this.refs.loginPassphrase.value = ''; this.refs.loginPassphraseTextarea.value = ''; - - this.sync(); } logout() { @@ -466,8 +465,8 @@ class NotaryElectionsModal extends React.Component { _items.push( { _history[i].address } - { Number(_history[i].amount) } - { this.renderHistoryRegion(_history[i].region) } + { _history[i].amount === 'unknown' ? 'unknown' : Number(_history[i].amount) } + { _history[i].region === 'unknown' ? 'unknown' : this.renderHistoryRegion(_history[i].region) } { secondsToString(_history[i].timestamp) } ); @@ -612,6 +611,7 @@ class NotaryElectionsModal extends React.Component { } { this.state.isAuth && + this.state.userType === 'voter' &&