Skip to content

Commit

Permalink
handle quotes with unknown eta (#2950)
Browse files Browse the repository at this point in the history
  • Loading branch information
artursapek authored Nov 11, 2024
1 parent 16ca52b commit 5534a95
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion wormhole-connect/src/hooks/useSortedRoutesWithQuotes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,8 @@ const bucketByEta = (
const { quote } = routeAndQuote;
for (let i = 0; i < thresholds.length; i++) {
const threshold = thresholds[i];
if (quote.eta && quote.eta <= threshold) {
const eta = quote.eta ?? Infinity;
if (eta <= threshold) {
buckets[i].push(routeAndQuote);
break;
}
Expand Down

0 comments on commit 5534a95

Please sign in to comment.