mirror of
https://github.com/streamwall/streamwall.git
synced 2026-01-25 06:32:49 -05:00
Stop filtering out offline/unknown streams from list
This commit is contained in:
@@ -8,13 +8,6 @@ import chokidar from 'chokidar'
|
||||
|
||||
const sleep = promisify(setTimeout)
|
||||
|
||||
function filterLive(data) {
|
||||
return data.filter(
|
||||
({ kind, status }) =>
|
||||
(kind && kind !== 'video') || status === 'Live' || status === 'Unknown',
|
||||
)
|
||||
}
|
||||
|
||||
export async function* pollDataURL(url, intervalSecs) {
|
||||
const refreshInterval = intervalSecs * 1000
|
||||
let lastData = []
|
||||
@@ -31,7 +24,7 @@ export async function* pollDataURL(url, intervalSecs) {
|
||||
if (!data.length && lastData.length) {
|
||||
console.warn('using cached stream data')
|
||||
} else {
|
||||
yield filterLive(data)
|
||||
yield data
|
||||
lastData = data
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user