mirror of
https://github.com/status-im/eth2.0-specs.git
synced 2025-01-12 19:54:34 +00:00
Update test_libs/pyspec/eth2spec/utils/ssz/ssz_impl.py
Co-Authored-By: vbuterin <v@buterin.com>
This commit is contained in:
parent
54a1fa9abe
commit
3a9b1fb72c
@ -169,7 +169,7 @@ def hash_tree_root(obj, typ):
|
||||
fields = get_typed_values(obj, typ=typ)
|
||||
leaves = [hash_tree_root(field_value, typ=field_typ) for field_value, field_typ in fields]
|
||||
if is_list_kind(typ):
|
||||
return mix_in_length(merkleize_chunks(leaves, pad_to=typ.length), len(obj))
|
||||
return mix_in_length(merkleize_chunks(leaves, pad_to=chunk_count(typ)), len(obj))
|
||||
else:
|
||||
return merkleize_chunks(leaves)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user