mirror of
https://github.com/lightninglabs/pool.git
synced 2026-08-19 13:17:51 +02:00
rpcserver: check min units match
This commit is contained in:
parent
31f714dafc
commit
4e12074f0a
1 changed files with 4 additions and 0 deletions
|
|
@ -1864,6 +1864,10 @@ func (s *rpcServer) CancelOrder(ctx context.Context,
|
|||
func (s *rpcServer) QuoteOrder(ctx context.Context,
|
||||
req *poolrpc.QuoteOrderRequest) (*poolrpc.QuoteOrderResponse, error) {
|
||||
|
||||
if req.MinUnitsMatch == 0 {
|
||||
return nil, fmt.Errorf("min units match must be specified")
|
||||
}
|
||||
|
||||
auctionTerms, err := s.auctioneer.Terms(ctx)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("unable to query auctioneer terms: %v",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue