diff --git a/packages/indexer-nibi/src/node-test.ts b/packages/indexer-nibi/src/node-test.ts index 79db610c..e93e526d 100644 --- a/packages/indexer-nibi/src/node-test.ts +++ b/packages/indexer-nibi/src/node-test.ts @@ -1,12 +1,14 @@ import { HeartMonitor } from "./heart-monitor" + ;(async () => { const hm = new HeartMonitor() - const b = await hm.markPriceCandlesSubscription({}) - - for await (const event of b) { - console.log(event) + const test = await hm.markPriceCandlesSubscription({}) + if (test) { + for await (const event of test) { + console.log(event) - // complete a running subscription by breaking the iterator loop - // break + // complete a running subscription by breaking the iterator loop + // break + } } })()