diff --git a/app/checker/checker.go b/app/checker/checker.go index fd480ca..811af3e 100644 --- a/app/checker/checker.go +++ b/app/checker/checker.go @@ -143,6 +143,11 @@ func CheckChannels(pls playlist.Playlist) playlist.Playlist { } count := len(pls.Channels) + if count == 0 { + log.Println("There are no channels to check, skipping") + return pls + } + timeout, routines := calcParameters(count) httpClient := http.Client{Timeout: timeout} chSemaphores := make(chan struct{}, routines)