This commit is contained in:
freearhey 2021-03-12 17:51:59 +03:00
parent 7e1904fdfa
commit 82cc8e648c
7 changed files with 138 additions and 16 deletions

View file

@ -40,7 +40,13 @@ async function main() {
.get(item.url)
.then(response => {
const parserOptions = Object.assign({}, item, config, { content: response.data })
const programs = config.parser(parserOptions).filter(i => i)
const programs = config
.parser(parserOptions)
.filter(i => i)
.map(p => {
p.channel = item.channel.xmltv_id
return p
})
console.log(
` ${item.channel.site} - ${item.channel.xmltv_id} - ${item.date.format(