Spaces:
Runtime error
Runtime error
Update mychain.py
Browse files- mychain.py +2 -2
mychain.py
CHANGED
@@ -507,8 +507,8 @@ class MyChainTrans:
|
|
507 |
def reset(self,create=None):
|
508 |
self.chain = []
|
509 |
self.pending_transactions = []
|
510 |
-
self.create_block(proof=1, previous_hash='0',chain_n=create)
|
511 |
-
def create_block(self,
|
512 |
if chain_r=="" or chain_r==None:
|
513 |
chain_r=f"{main_chain_trans.split('datasets/',1)[1].split('/raw',1)[0]}"
|
514 |
if chain_n !="" and chain_n !=None:
|
|
|
507 |
def reset(self,create=None):
|
508 |
self.chain = []
|
509 |
self.pending_transactions = []
|
510 |
+
self.create_block(balanc=0, proof=1, previous_hash='0',chain_n=create)
|
511 |
+
def create_block(self,balance, proof, previous_hash,prev_block=None,chain_r=None,chain_n=None):
|
512 |
if chain_r=="" or chain_r==None:
|
513 |
chain_r=f"{main_chain_trans.split('datasets/',1)[1].split('/raw',1)[0]}"
|
514 |
if chain_n !="" and chain_n !=None:
|