Skip to content

Commit 4383b6f

Browse files
authored
CHIA-1465 Simplify double spend validation in validate_block_body (#18628)
Simplify double spend validation in validate_block_body.
1 parent 44db523 commit 4383b6f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

chia/consensus/block_body_validation.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -367,8 +367,8 @@ async def validate_block_body(
367367

368368
# 14. Check for duplicate spends inside block
369369
removal_counter = collections.Counter(removals)
370-
for k, v in removal_counter.items():
371-
if v > 1:
370+
for count in removal_counter.values():
371+
if count > 1:
372372
return Err.DOUBLE_SPEND, None
373373

374374
# 15. Check if removals exist and were not previously spent. (unspent_db + diff_store + this_block)

0 commit comments

Comments
 (0)