Update generate.js

This commit is contained in:
freearhey 2021-02-10 17:14:43 +03:00
parent f0c88d293c
commit e50b1251fc
1 changed files with 14 additions and 0 deletions

View File

@ -160,6 +160,13 @@ function generateCountries() {
utils.appendToFile(filename, channel.toString())
}
}
const other = `${outputDir}/undefined.m3u`
const channels = db.channels.sortBy(['name', 'url']).forCountry({ code: null })
utils.createFile(other, '#EXTM3U\n')
for (const channel of channels) {
utils.appendToFile(other, channel.toString())
}
}
function generateLanguages() {
@ -176,6 +183,13 @@ function generateLanguages() {
utils.appendToFile(filename, channel.toString())
}
}
const other = `${outputDir}/undefined.m3u`
const channels = db.channels.sortBy(['name', 'url']).forLanguage({ code: null })
utils.createFile(other, '#EXTM3U\n')
for (const channel of channels) {
utils.appendToFile(other, channel.toString())
}
}
function finish() {