From 0b9d6939f32933d6d4b2d37be83cbfbcd4d289ce Mon Sep 17 00:00:00 2001 From: c9s Date: Thu, 21 Jul 2022 01:22:28 +0800 Subject: [PATCH] indicator/till: add zero time check --- pkg/indicator/till.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/indicator/till.go b/pkg/indicator/till.go index 33cb9bc8d..1059ed3e1 100644 --- a/pkg/indicator/till.go +++ b/pkg/indicator/till.go @@ -87,7 +87,7 @@ func (inc *TILL) Length() int { var _ types.Series = &TILL{} func (inc *TILL) PushK(k types.KLine) { - if k.EndTime.Before(inc.e1.EndTime) { + if inc.e1.EndTime != zeroTime && k.EndTime.Before(inc.e1.EndTime) { return }