diff --git a/pkg/telemetry/interceptor.go b/pkg/telemetry/interceptor.go index 5dbbff31c..08fba08f8 100644 --- a/pkg/telemetry/interceptor.go +++ b/pkg/telemetry/interceptor.go @@ -6,6 +6,14 @@ import ( "github.com/pion/rtcp" ) +func (t *TelemetryService) NewStatsInterceptorFactory(participantID, identity string) *StatsInterceptorFactory { + return &StatsInterceptorFactory{ + t: t, + participantID: participantID, + identity: identity, + } +} + type StatsInterceptorFactory struct { t *TelemetryService participantID string diff --git a/pkg/telemetry/service.go b/pkg/telemetry/service.go index b68ac10e6..118736c41 100644 --- a/pkg/telemetry/service.go +++ b/pkg/telemetry/service.go @@ -39,14 +39,6 @@ func NewTelemetryService(notifier webhook.Notifier) *TelemetryService { } } -func (t *TelemetryService) NewStatsInterceptorFactory(participantID, identity string) *StatsInterceptorFactory { - return &StatsInterceptorFactory{ - t: t, - participantID: participantID, - identity: identity, - } -} - func (t *TelemetryService) OnDownstreamPacket(participantID string, bytes int) { t.RLock() w := t.workers[participantID]