Skip to content

Commit

Permalink
start watching 1st
Browse files Browse the repository at this point in the history
  • Loading branch information
mrq1911 committed Jan 14, 2025
1 parent d0bb11a commit 70f0033
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/bot.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,10 @@ async function main() {
await endpoints.start();

const events = new Events();

console.log('watching for new blocks');
events.startWatching();

events.addHandler(currenciesHandler);
events.addHandler(xyk);
events.addHandler(lbp);
Expand Down Expand Up @@ -67,9 +71,6 @@ async function main() {
await events.emitFromBlock(i);
}
}

console.log('watching for new blocks');
events.startWatching();
}

main().catch(err => {
Expand Down

0 comments on commit 70f0033

Please sign in to comment.