grid2: fix precheck

This commit is contained in:
c9s 2023-05-26 16:09:07 +08:00
parent a7a4660b2e
commit 5ef7da8422
No known key found for this signature in database
GPG Key ID: 7385E7E464CB0A54

View File

@ -236,7 +236,7 @@ func (s *Strategy) Validate() error {
}
}
if !s.QuantityOrAmount.IsSet() && s.QuoteInvestment.IsZero() {
if !s.QuantityOrAmount.IsSet() && s.QuoteInvestment.IsZero() && s.BaseInvestment.IsZero() {
return fmt.Errorf("either quantity, amount or quoteInvestment must be set")
}