mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-10 09:11:55 +00:00
grid2: ignore discounted trades
This commit is contained in:
parent
f2109afa0e
commit
43b8e7870d
|
@ -9,6 +9,10 @@ import (
|
|||
func collectTradeFee(trades []types.Trade) map[string]fixedpoint.Value {
|
||||
fees := make(map[string]fixedpoint.Value)
|
||||
for _, t := range trades {
|
||||
if t.FeeDiscounted {
|
||||
continue
|
||||
}
|
||||
|
||||
if fee, ok := fees[t.FeeCurrency]; ok {
|
||||
fees[t.FeeCurrency] = fee.Add(t.Fee)
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue
Block a user