Update findblock.php

Fixed Invalid Blockhash for listsinceblock.
This commit is contained in:
Kyle Tse 2017-09-29 05:01:20 +08:00 committed by GitHub
parent 6c1aa15879
commit 15c7c02268

View File

@ -28,7 +28,9 @@ require_once('shared.inc.php');
// Fetch our last block found from the DB as a starting point
$aLastBlock = @$block->getLastValid();
$strLastBlockHash = $aLastBlock['blockhash'];
if (!$strLastBlockHash) $strLastBlockHash = '';
if (!$strLastBlockHash) {
$strLastBlockHash = $bitcoin->getblockhash(1);
}
// Fetch all transactions since our last block
if ( $bitcoin->can_connect() === true ){