[ENG-585]: Setting min bid increment in ante (#28)

This commit is contained in:
David Terpay
2023-03-16 19:40:09 -04:00
committed by GitHub
parent b6da342a49
commit fdfd12a81d
5 changed files with 74 additions and 11 deletions
+10
View File
@@ -158,6 +158,16 @@ func (am *AuctionMempool) RemoveWithoutRefTx(tx sdk.Tx) error {
return nil
}
// GetTopAuctionTx returns the highest bidding transaction in the auction mempool.
func (am *AuctionMempool) GetTopAuctionTx(ctx context.Context) sdk.Tx {
iterator := am.auctionIndex.Select(ctx, nil)
if iterator == nil {
return nil
}
return iterator.Tx()
}
// AuctionBidSelect returns an iterator over auction bids transactions only.
func (am *AuctionMempool) AuctionBidSelect(ctx context.Context) sdkmempool.Iterator {
return am.auctionIndex.Select(ctx, nil)