mirror of
https://github.com/bitcoinj/bitcoinj.git
synced 2024-11-19 18:00:39 +01:00
BuildCheckpoints: Print time of checkpoint blocks.
This commit is contained in:
parent
7f2645fe16
commit
bd080ac5e4
@ -125,8 +125,8 @@ public class BuildCheckpoints {
|
||||
public void notifyNewBestBlock(StoredBlock block) throws VerificationException {
|
||||
int height = block.getHeight();
|
||||
if (height % params.getInterval() == 0 && block.getHeader().getTimeSeconds() <= timeAgo) {
|
||||
System.out.println(String.format("Checkpointing block %s at height %d",
|
||||
block.getHeader().getHash(), block.getHeight()));
|
||||
System.out.println(String.format("Checkpointing block %s at height %d, time %s",
|
||||
block.getHeader().getHash(), block.getHeight(), Utils.dateTimeFormat(block.getHeader().getTime())));
|
||||
checkpoints.put(height, block);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user