pub fn add_block(&mut self, block: Block) -> Result<BlockHeight, String> {
        self.balances
            .add_payment(&block.transaction.operation)
            .map_err(|e| format!("failed to execute transfer {:?}: {:?}", block, e))?;
        self.blockchain.add_block(block)
    }
/// This adds a pre created block to the ledger. This should only be used
/// during canister migration or upgrade
This adds a pre created block to the ledger. This should only be used
during canister migration or upgrade
This adds a pre created block to the ledger . This should only be used during canister migration or upgrade
pub fn add_block(&mut self, block: Block) -> Result<BlockHeight, String> {
        self.balances
            .add_payment(&block.transaction.operation)
            .map_err(|e| format!("failed to execute transfer {:?}: {:?}", block, e))?;
        self.blockchain.add_block(block)
    }
pub fn add_block ( & mut self , block : Block ) -> Result < BlockHeight , String > { self . balances . add_payment ( & block . transaction . operation ) . map_err ( | e | format ! ( " " block e ) ) ? ; self . blockchain . add_block ( block ) }
This adds a pre created block to the ledger.
This adds a pre created block to the ledger .
&mut self
block
Block
&mut self
block
Block