From d7f97423600df9fba381a86ecad3d2544b43ea56 Mon Sep 17 00:00:00 2001 From: c9s Date: Tue, 7 Jun 2022 00:50:07 +0800 Subject: [PATCH] binance: revert the start time filtering --- pkg/exchange/binance/exchange.go | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/pkg/exchange/binance/exchange.go b/pkg/exchange/binance/exchange.go index ccfcdc3b9..18f2612ca 100644 --- a/pkg/exchange/binance/exchange.go +++ b/pkg/exchange/binance/exchange.go @@ -1240,18 +1240,11 @@ func (e *Exchange) QueryKLines(ctx context.Context, symbol string, interval type var kLines []types.KLine for _, k := range resp { - startTime := types.NewTimeFromUnix(0, k.OpenTime*int64(time.Millisecond)) - if options.EndTime != nil { - if !startTime.Before(*options.EndTime) { - continue - } - } - kLines = append(kLines, types.KLine{ Exchange: types.ExchangeBinance, Symbol: symbol, Interval: interval, - StartTime: startTime, + StartTime: types.NewTimeFromUnix(0, k.OpenTime*int64(time.Millisecond)), EndTime: types.NewTimeFromUnix(0, k.CloseTime*int64(time.Millisecond)), Open: fixedpoint.MustNewFromString(k.Open), Close: fixedpoint.MustNewFromString(k.Close),