Add back indent and sort_keys
This commit is contained in:
parent
f0274fdfa8
commit
14fc2396f3
2
block.py
2
block.py
@ -28,7 +28,7 @@ def write_json(block: Block):
|
|||||||
write_mode = "w" if cache_path.is_file() else "x"
|
write_mode = "w" if cache_path.is_file() else "x"
|
||||||
|
|
||||||
with open(cache_path, mode=write_mode) as cache_file:
|
with open(cache_path, mode=write_mode) as cache_file:
|
||||||
cache_file.write(block.json())
|
cache_file.write(block.json(sort_keys=True, indent=4))
|
||||||
|
|
||||||
|
|
||||||
## Creates a block object, either from the cache or from the chain itself
|
## Creates a block object, either from the cache or from the chain itself
|
||||||
|
Loading…
x
Reference in New Issue
Block a user