Skip to content

Commit

Permalink
Log warning when there are no active dAPIs
Browse files Browse the repository at this point in the history
  • Loading branch information
Siegrift committed Nov 9, 2023
1 parent 45f6481 commit cac0f18
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/update-feeds/update-feeds.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,10 @@ export const runUpdateFeed = async (providerName: ProviderName, chain: Chain, ch
return;
}
const { firstBatch, dapisCount } = goFirstBatch.data;
// TODO: Handle case when there are no dAPIs.
if (dapisCount === 0) {
logger.warn(`No active dAPIs found`);
return;
}
const processFirstBatchPromise = processBatch(firstBatch, providerName, chainId);

// Calculate the stagger time between the rest of the batches.
Expand Down

0 comments on commit cac0f18

Please sign in to comment.