diff options
| author | LLLL Colonq <llll@colonq> | 2025-06-08 03:50:02 -0400 |
|---|---|---|
| committer | LLLL Colonq <llll@colonq> | 2025-06-08 03:50:02 -0400 |
| commit | c45abd29a5e4a9146cbe94789b7b3787eb02e5a5 (patch) | |
| tree | cab59a933432c6084ab55fefe3cf36afb9ae1af1 | |
| parent | fab556994c2127663253a2d14d379d35dc09b981 (diff) | |
fig-monitor-twitch: Log a bit more politely in liveness watcher
| -rw-r--r-- | fig-monitor-twitch/src/Fig/Monitor/Twitch.hs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/fig-monitor-twitch/src/Fig/Monitor/Twitch.hs b/fig-monitor-twitch/src/Fig/Monitor/Twitch.hs index 5f97209..d4eca81 100644 --- a/fig-monitor-twitch/src/Fig/Monitor/Twitch.hs +++ b/fig-monitor-twitch/src/Fig/Monitor/Twitch.hs @@ -478,7 +478,9 @@ twitchChannelLiveMonitor cfg busAddr = do loop = do log "Updating liveness..." live <- runAuthed cfg $ usersAreLive cfg.monitor - log $ "Update complete! Live users: " <> Text.unwords (Set.toList live) + if null live + then log "Update complete! No users live" + else log $ "Update complete! Live users: " <> Text.unwords (Set.toList live) cmds.publish "monitor twitch stream online" . encodeUtf8 . Text.unwords $ Set.toList live threadDelay $ 5 * 60 * 1000000 -- wait 5 minutes loop |
