Skip to content

Commit c7f0210

Browse files
Add type hints for __init__ methods
1 parent aeaf25e commit c7f0210

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

blockchain/simple_blockchain.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class Block:
2727
hash (str): SHA256 hash of the block's content.
2828
"""
2929

30-
def __init__(self, index: int, data: str, previous_hash: str, difficulty: int = 2):
30+
def __init__(self, index: int, data: str, previous_hash: str, difficulty: int = 2) -> None:
3131
self.index = index
3232
self.timestamp = time()
3333
self.data = data

0 commit comments

Comments
 (0)