mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-22 14:55:16 +00:00
grid2: pull out sell boolean var
This commit is contained in:
parent
0c6ef38ea3
commit
2046ccc791
|
@ -1336,8 +1336,8 @@ func (s *Strategy) generateGridOrders(totalQuote, totalBase, lastPrice fixedpoin
|
|||
quantity = s.QuantityOrAmount.Amount.Div(price)
|
||||
}
|
||||
|
||||
// TODO: add fee if we don't have the platform token. BNB, OKB or MAX...
|
||||
if price.Compare(lastPrice) >= 0 {
|
||||
placeSell := price.Compare(lastPrice) >= 0
|
||||
if placeSell {
|
||||
si = i
|
||||
|
||||
// do not place sell order when i == 0 (the bottom of grid)
|
||||
|
|
Loading…
Reference in New Issue
Block a user