Skip to content

Commit

Permalink
fix: fix missing update on the latest block
Browse files Browse the repository at this point in the history
  • Loading branch information
anxolin committed Dec 7, 2024
1 parent a6aaf36 commit e7dc90c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/services/chain.ts
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,8 @@ export class ChainContext {
log.debug(`Watchdog timeout: ${watchdogTimeout} seconds`);
let lastBlockReceived = lastProcessedBlock;
provider.on("block", async (blockNumber: number) => {
metrics.blockHeight.labels(chainId.toString()).set(blockNumber);

try {
log = getLogger({
name: loggerName,
Expand Down

0 comments on commit e7dc90c

Please sign in to comment.