addBlock({ data }) {
    const lastBlock = this.chain[this.chain.length - 1];
    const newBlock = Block.mineBlock({
      lastBlock,
      data
    });

    this.chain.push(newBlock);
  }
// ADD A BLOCK TO THE CHAIN
ADD A BLOCK TO THE CHAIN
ADD A BLOCK TO THE CHAIN
addBlock({ data }) {
    const lastBlock = this.chain[this.chain.length - 1];
    const newBlock = Block.mineBlock({
      lastBlock,
      data
    });
    this.chain.push(newBlock);
  }
addBlock ( { data } ) { const lastBlock = this . chain [ this . chain . length - 1 ] ; const newBlock = Block . mineBlock ( { lastBlock , data } ) ; this . chain . push ( newBlock ) ; }
ADD A BLOCK TO THE CHAIN
ADD A BLOCK TO THE CHAIN