From 1d76ad65ec4dcde8666d57344057d9060ed30b7f Mon Sep 17 00:00:00 2001 From: Justin Date: Tue, 5 Feb 2019 11:49:52 -0800 Subject: [PATCH] Update 0_beacon-chain.md --- specs/core/0_beacon-chain.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/specs/core/0_beacon-chain.md b/specs/core/0_beacon-chain.md index ed5d1b3b3..6b41e6c8a 100644 --- a/specs/core/0_beacon-chain.md +++ b/specs/core/0_beacon-chain.md @@ -1100,10 +1100,9 @@ def verify_bitfield(bitfield: bytes, committee_size: int) -> bool: return False # Check if `bitfield` has padding zeros - if committee_size % 8 != 0: - for i in range(committee_size, committee_size - committee_size % 8 + 8): - if get_bitfield_bit(bitfield, i) == 0b1: - return False + for i in range(committee_size, len(bitfield) * 8): + if get_bitfield_bit(bitfield, i) == 0b1: + return False return True ```