Skip to content

Commit

Permalink
♻️ Change integer to more descreptive variablein delegate Statistics
Browse files Browse the repository at this point in the history
  • Loading branch information
michaeltomasik committed Jun 27, 2018
1 parent 7536d8a commit cc20dc0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/components/transactions/delegateStatistics.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,17 @@ import grid from 'flexboxgrid/dist/flexboxgrid.css';
import { translate } from 'react-i18next';
import UserVotes from './userVotes';
import VotedDelegates from './votedDelegates';
import voting from '../../constants/voting';
import styles from './delegateStatistics.css';

class DelegateStatistics extends React.Component {
render() {
const { delegate } = this.props;

let status = '';

if (delegate && delegate.rank) {
status = delegate.rank <= 101 ? this.props.t('Active') : this.props.t('Standby');
status = delegate.rank <= voting.maxCountOfVotes ? this.props.t('Active') : this.props.t('Standby');
}

const missed = this.props.t('missed');
Expand Down

0 comments on commit cc20dc0

Please sign in to comment.