mirror of
https://github.com/iptv-org/epg.git
synced 2025-05-10 09:00:07 -04:00
Update mts.rs
This commit is contained in:
parent
1458e7f298
commit
7294acbe4c
2 changed files with 1 additions and 11 deletions
|
@ -17,11 +17,6 @@ module.exports = {
|
||||||
'X-Requested-With': 'XMLHttpRequest'
|
'X-Requested-With': 'XMLHttpRequest'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
logo({ content, channel }) {
|
|
||||||
const data = parseContent(content, channel)
|
|
||||||
|
|
||||||
return data ? data.image : null
|
|
||||||
},
|
|
||||||
parser: function ({ content, channel, date }) {
|
parser: function ({ content, channel, date }) {
|
||||||
let programs = []
|
let programs = []
|
||||||
const data = parseContent(content, channel)
|
const data = parseContent(content, channel)
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
// npx epg-grabber --config=sites/mts.rs/mts.rs.config.js --channels=sites/mts.rs/mts.rs_rs.channels.xml --output=.gh-pages/guides/rs/mts.rs.epg.xml --days=2
|
// npx epg-grabber --config=sites/mts.rs/mts.rs.config.js --channels=sites/mts.rs/mts.rs_rs.channels.xml --output=.gh-pages/guides/rs/mts.rs.epg.xml --days=2
|
||||||
|
|
||||||
const { parser, url, logo, request } = require('./mts.rs.config.js')
|
const { parser, url, request } = require('./mts.rs.config.js')
|
||||||
const dayjs = require('dayjs')
|
const dayjs = require('dayjs')
|
||||||
const utc = require('dayjs/plugin/utc')
|
const utc = require('dayjs/plugin/utc')
|
||||||
const customParseFormat = require('dayjs/plugin/customParseFormat')
|
const customParseFormat = require('dayjs/plugin/customParseFormat')
|
||||||
|
@ -25,11 +25,6 @@ it('can generate valid request headers', () => {
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
it('can get logo url', () => {
|
|
||||||
const result = logo({ content, channel })
|
|
||||||
expect(result).toBe('https://mts.rs/oec/images/tv_channels/904ddd8cd6720a4a1c23eae513b5b957.jpg')
|
|
||||||
})
|
|
||||||
|
|
||||||
it('can parse response', () => {
|
it('can parse response', () => {
|
||||||
const result = parser({ date, channel, content }).map(p => {
|
const result = parser({ date, channel, content }).map(p => {
|
||||||
p.start = p.start.toJSON()
|
p.start = p.start.toJSON()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue