From 44cb952c29ea499ff90e29490a4fb421d7e71d27 Mon Sep 17 00:00:00 2001 From: Gabe Kangas Date: Wed, 12 Jan 2022 21:03:50 -0800 Subject: [PATCH] Increase the timeout buffer so viewer count doesn't jump around when not pinging --- core/stats.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/core/stats.go b/core/stats.go index 1398dbf0e..4df3dc403 100644 --- a/core/stats.go +++ b/core/stats.go @@ -11,8 +11,10 @@ import ( "github.com/owncast/owncast/models" ) -var l = &sync.RWMutex{} -var _activeViewerPurgeTimeout = time.Second * 10 +var ( + l = &sync.RWMutex{} + _activeViewerPurgeTimeout = time.Second * 15 +) func setupStats() error { s := getSavedStats()