Skip to content

Commit

Permalink
Make code more readable
Browse files Browse the repository at this point in the history
  • Loading branch information
jessepinho committed May 17, 2024
1 parent 4642886 commit 42c3fef
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/services/src/view-service/auctions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,10 @@ export const auctions: Impl['auctions'] = async function* (req, ctx) {
}

let state: DutchAuctionState | undefined;
if (queryLatestState) state = (await querier.auction.auctionStateById(id))?.state;
if (queryLatestState) {
const auction = await querier.auction.auctionStateById(id);
state = auction?.state;
}

const outstandingReserves = await indexedDb.getAuctionOutstandingReserves(id);

Expand Down

0 comments on commit 42c3fef

Please sign in to comment.