mirror of
https://github.com/iptv-org/iptv.git
synced 2025-05-13 10:30:03 -04:00
Update format.js
This commit is contained in:
parent
80ce577313
commit
7888841f17
1 changed files with 7 additions and 2 deletions
|
@ -237,8 +237,13 @@ function updateLogo(channel, data, epgData) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function updateTvgLanguage(channel, data) {
|
function updateTvgLanguage(channel, data) {
|
||||||
if (!channel.tvg.language && data) {
|
if (!channel.tvg.language) {
|
||||||
channel.tvg.language = data.languages.map(l => l.name).join(';')
|
if (data) {
|
||||||
|
channel.tvg.language = data.languages.map(l => l.name).join(';')
|
||||||
|
} else if (channel.countries.length) {
|
||||||
|
const countryCode = channel.countries[0].code
|
||||||
|
channel.tvg.language = utils.country2language(countryCode)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue