mirror of
https://github.com/iptv-org/epg.git
synced 2025-05-11 09:30:06 -04:00
Reinstate what was PR made for
This commit is contained in:
parent
a32f80a0ff
commit
d3649ee1a8
1 changed files with 4 additions and 14 deletions
|
@ -21,20 +21,10 @@ module.exports = {
|
|||
if (!data.events) return programs
|
||||
|
||||
data.events.forEach(item => {
|
||||
if (item.title && item.startTime && item.endTime) {
|
||||
const start = dayjs
|
||||
.utc(item.startTime, 'HH:mm')
|
||||
.set('D', date.get('D'))
|
||||
.set('M', date.get('M'))
|
||||
.set('y', date.get('y'))
|
||||
.toString()
|
||||
|
||||
const stop = dayjs
|
||||
.utc(item.endTime, 'HH:mm')
|
||||
.set('D', date.get('D'))
|
||||
.set('M', date.get('M'))
|
||||
.set('y', date.get('y'))
|
||||
.toString()
|
||||
if (item.title && item.startTime && item.duration) {
|
||||
const start = parseStart(item, date)
|
||||
const duration = parseInt(item.duration)
|
||||
const stop = start.add(duration, 'm')
|
||||
|
||||
programs.push({
|
||||
title: item.displayTitle || item.title,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue