From 73e0ea9223c5f332c7ae02aa73533def6f5c3902 Mon Sep 17 00:00:00 2001 From: Aleksandr Statciuk Date: Wed, 3 Nov 2021 09:48:28 +0300 Subject: [PATCH 1/2] Update format.js --- scripts/format.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/format.js b/scripts/format.js index c66f4cd0d6..cbe09f66cd 100644 --- a/scripts/format.js +++ b/scripts/format.js @@ -130,8 +130,10 @@ function updateStatus(channel, status) { case 'online': channel.status = channel.status === 'Offline' ? 'Not 24/7' : null break - case 'offline': case 'error_403': + channel.status = 'Geo-blocked' + break + case 'offline': channel.status = 'Offline' break } From 019a63e567e0fe352ad8a2c3e6f57bd186392d54 Mon Sep 17 00:00:00 2001 From: Aleksandr Statciuk Date: Wed, 3 Nov 2021 12:42:50 +0300 Subject: [PATCH 2/2] Update format.js --- scripts/format.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/scripts/format.js b/scripts/format.js index cbe09f66cd..2c78c1addd 100644 --- a/scripts/format.js +++ b/scripts/format.js @@ -8,7 +8,7 @@ const file = require('./helpers/file') const log = require('./helpers/log') const epg = require('./helpers/epg') -const ignoreStatus = ['Geo-blocked', 'Not 24/7'] +const ignoreStatus = ['Geo-blocked'] program .usage('[OPTIONS]...') @@ -128,13 +128,14 @@ function updateOrigins(channel, requests) { function updateStatus(channel, status) { switch (status) { case 'online': - channel.status = channel.status === 'Offline' ? 'Not 24/7' : null + if (channel.status !== 'Not 24/7') + channel.status = channel.status === 'Offline' ? 'Not 24/7' : null break case 'error_403': channel.status = 'Geo-blocked' break case 'offline': - channel.status = 'Offline' + if (channel.status !== 'Not 24/7') channel.status = 'Offline' break } }