mirror of
https://github.com/iptv-org/iptv.git
synced 2025-05-12 18:10:04 -04:00
Installed iptv-playlist-parser
This commit is contained in:
parent
3d6d0cee3b
commit
d43e58bc26
3 changed files with 18 additions and 46 deletions
|
@ -26,14 +26,7 @@ async function main() {
|
|||
|
||||
const unsortedPlaylist = util.parsePlaylist('channels/unsorted.m3u')
|
||||
for(const item of unsortedPlaylist.items) {
|
||||
unsorted[item.url] = util.createChannel({
|
||||
id: item.inf['tvg-id'],
|
||||
name: item.inf['tvg-name'],
|
||||
logo: item.inf['tvg-logo'],
|
||||
group: item.inf['group-title'],
|
||||
url: item.url,
|
||||
title: item.inf.title
|
||||
})
|
||||
unsorted[item.url] = util.createChannel(item)
|
||||
}
|
||||
|
||||
for(let country of countries) {
|
||||
|
@ -55,14 +48,7 @@ async function main() {
|
|||
}
|
||||
let channels = []
|
||||
for(let item of playlist.items) {
|
||||
let channel = util.createChannel({
|
||||
id: item.inf['tvg-id'],
|
||||
name: item.inf['tvg-name'],
|
||||
logo: item.inf['tvg-logo'],
|
||||
group: item.inf['group-title'],
|
||||
url: item.url,
|
||||
title: item.inf.title
|
||||
})
|
||||
let channel = util.createChannel(item)
|
||||
|
||||
if(util.checkCache(channel.url)) {
|
||||
stats.duplicates++
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue