Browse Source

dump error message

main
ghost 10 months ago
parent
commit
716979a45f
  1. 16
      src/index.php

16
src/index.php

@ -142,6 +142,10 @@ if (isset($argv[1]))
// Begin crawler // Begin crawler
if (!$blocks = $kevacoin->getBlockCount()) if (!$blocks = $kevacoin->getBlockCount())
{ {
var_dump(
$kevacoin->getError()
);
exit( exit(
_('Could not receive blocks count!') _('Could not receive blocks count!')
); );
@ -160,6 +164,10 @@ for ($block = $state + 1; $block <= $blocks; $block++)
// Get block hash // Get block hash
if (!$hash = $kevacoin->getBlockHash($block)) if (!$hash = $kevacoin->getBlockHash($block))
{ {
var_dump(
$kevacoin->getError()
);
exit( exit(
sprintf( sprintf(
_('Could not receive "%d" block hash!'), _('Could not receive "%d" block hash!'),
@ -171,6 +179,10 @@ for ($block = $state + 1; $block <= $blocks; $block++)
// Get block data // Get block data
if (!$data = $kevacoin->getBlock($hash)) if (!$data = $kevacoin->getBlock($hash))
{ {
var_dump(
$kevacoin->getError()
);
exit( exit(
sprintf( sprintf(
_('Could not receive "%d" block data by hash "%s"!'), _('Could not receive "%d" block data by hash "%s"!'),
@ -200,6 +212,10 @@ for ($block = $state + 1; $block <= $blocks; $block++)
// Validate each transaction // Validate each transaction
if (!$raw = $kevacoin->getRawTransaction($transaction)) if (!$raw = $kevacoin->getRawTransaction($transaction))
{ {
var_dump(
$kevacoin->getError()
);
exit( exit(
sprintf( sprintf(
_('Could not receive raw transaction "%s" in block "%d"!'), _('Could not receive raw transaction "%s" in block "%d"!'),

Loading…
Cancel
Save