resolve other ret comment
This commit is contained in:
parent
f4de5e3c72
commit
207f632e1a
|
@ -91,13 +91,12 @@ def compute_committee(indices: List[ValidatorIndex], # type: ignore
|
||||||
|
|
||||||
# Monkey patch hash cache
|
# Monkey patch hash cache
|
||||||
_hash = hash
|
_hash = hash
|
||||||
hash_cache: Dict[bytes, Bytes32] = {}
|
hash_cache: Dict[bytes, Hash] = {}
|
||||||
|
|
||||||
|
|
||||||
def hash(x: bytes) -> Hash:
|
def hash(x: bytes) -> Hash:
|
||||||
if x not in hash_cache:
|
if x not in hash_cache:
|
||||||
ret = _hash(x)
|
hash_cache[x] = Hash(_hash(x))
|
||||||
hash_cache[x] = Hash(ret)
|
|
||||||
return hash_cache[x]
|
return hash_cache[x]
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue