From 3dff1acd795f3bcc37e676f2f21649f1c5818c30 Mon Sep 17 00:00:00 2001 From: TonyQ Date: Wed, 8 Dec 2021 19:36:37 +0800 Subject: [PATCH] finetune ftx for #318 --- pkg/exchange/ftx/stream.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkg/exchange/ftx/stream.go b/pkg/exchange/ftx/stream.go index 20836a534..3e3abcc5d 100644 --- a/pkg/exchange/ftx/stream.go +++ b/pkg/exchange/ftx/stream.go @@ -141,7 +141,9 @@ func (s *Stream) pollKLines(ctx context.Context) { if len(klines) > 0 { // handle mutiple klines, get the latest one - s.EmitKLineClosed(klines[len(klines)-1]) + kline := klines[len(klines)-1] + s.EmitKLine(kline) + s.EmitKLineClosed(kline) } }