diff --git a/pkg/report/profit_stats_tracker.go b/pkg/report/profit_stats_tracker.go index 9a0171010..9ad4c636b 100644 --- a/pkg/report/profit_stats_tracker.go +++ b/pkg/report/profit_stats_tracker.go @@ -20,8 +20,8 @@ type ProfitStatsTracker struct { tradeStats *types.TradeStats } -func (p *ProfitStatsTracker) Subscribe(session *bbgo.ExchangeSession) { - session.Subscribe(types.KLineChannel, p.Market.Symbol, types.SubscribeOptions{Interval: p.Interval}) +func (p *ProfitStatsTracker) Subscribe(session *bbgo.ExchangeSession, symbol string) { + session.Subscribe(types.KLineChannel, symbol, types.SubscribeOptions{Interval: p.Interval}) } // InitOld is for backward capability. ps is the ProfitStats of the strategy, Market is the strategy Market diff --git a/pkg/strategy/supertrend/strategy.go b/pkg/strategy/supertrend/strategy.go index da904a064..ea5764a77 100644 --- a/pkg/strategy/supertrend/strategy.go +++ b/pkg/strategy/supertrend/strategy.go @@ -133,7 +133,7 @@ func (s *Strategy) Subscribe(session *bbgo.ExchangeSession) { // Profit tracker if s.ProfitStatsTracker != nil { - s.ProfitStatsTracker.Subscribe(session) + s.ProfitStatsTracker.Subscribe(session, s.Symbol) } }