fixed vote counting

This commit is contained in:
ryan 2016-04-28 15:33:08 +02:00
parent 0b22d65241
commit 1f7e1893f9

View File

@ -482,10 +482,9 @@ class Bigchain(object):
"""
n_voters = len(block['block']['voters'])
vote_list = [vote['vote']['is_block_valid'] for vote in block['votes']]
vote_list = [vote['vote']['is_block_valid'] for vote in block['block']['votes']]
n_invalid_votes = vote_list.count(False)
if n_invalid_votes >= int(n_voters/2):
return True
else: