Commit f72e069d authored by adcpm's avatar adcpm

Send callback with skipped block number

parent 6ad12402
......@@ -281,9 +281,19 @@ class Steem extends EventEmitter {
const blockId = mode === 'irreversible'
? result.last_irreversible_block_num
: result.head_block_number;
if (blockId !== current) {
current = blockId;
callback(null, current);
if (current) {
for (let i = current; i < blockId; i++) {
if (i !== current) {
callback(null, i);
}
current = i;
}
} else {
current = blockId;
callback(null, blockId);
}
}
Promise.delay(ts).then(() => {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment