From bf04b5f2fb5140b37f08763a505e984112a1706f Mon Sep 17 00:00:00 2001 From: Aleksandr Statciuk Date: Sat, 10 Sep 2022 16:45:37 +0300 Subject: [PATCH] Update update.js --- scripts/commands/playlist/update.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/scripts/commands/playlist/update.js b/scripts/commands/playlist/update.js index 6799e34e95..f60411e307 100644 --- a/scripts/commands/playlist/update.js +++ b/scripts/commands/playlist/update.js @@ -9,7 +9,14 @@ async function main() { const levels = { online: 1, blocked: 2, timeout: 3, error: 4, default: 5 } streams = orderBy( streams, - ['channel', s => levels[s.status] || levels['default'], 'title', 'height', 'frame_rate', 'url'], + [ + 'channel', + s => (s.channel ? '' : s.title), + s => levels[s.status] || levels['default'], + 'height', + 'frame_rate', + 'url' + ], ['asc', 'asc', 'asc', 'desc', 'desc', 'asc'] )