Merge pull request #1979 from iptv-org/remove-json-version

Remove JSON version of the guides
This commit is contained in:
Ministorm3 2023-02-08 07:01:28 -05:00 committed by GitHub
commit 79d5ec772d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 2 additions and 43 deletions

View file

@ -91,15 +91,12 @@ async function save(filepath, programs) {
const xmlFilepath = `${PUBLIC_DIR}/guides/${filepath}.xml`
const gzFilepath = `${PUBLIC_DIR}/guides/${filepath}.xml.gz`
const jsonFilepath = `${PUBLIC_DIR}/guides/${filepath}.json`
logger.info(`creating ${xmlFilepath}...`)
const xmltv = generateXMLTV(output)
await file.create(xmlFilepath, xmltv)
logger.info(`creating ${gzFilepath}...`)
const compressed = await zip.compress(xmltv)
await file.create(gzFilepath, compressed)
logger.info(`creating ${jsonFilepath}...`)
await file.create(jsonFilepath, JSON.stringify(output))
return output
}