mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-28 18:21:26 +01:00
Compare commits
2 Commits
6a3ae2c0bc
...
d009450b4f
Author | SHA1 | Date | |
---|---|---|---|
|
d009450b4f | ||
|
6b469573db |
|
@ -85,8 +85,9 @@ class RedCDNLivxIE(InfoExtractor):
|
|||
|
||||
# no id or title for a transmission. making ones up.
|
||||
title = path \
|
||||
.replace('/live/', '/').replace('/live', '').replace('live/', '') \
|
||||
.replace('/channel/', '/').replace('/channel', '').replace('channel/', '')
|
||||
.replace('/live', '').replace('live/', '') \
|
||||
.replace('/channel', '').replace('channel/', '') \
|
||||
.strip('/')
|
||||
video_id = join_nonempty(title.replace('/', '-'), start_time, stop_time)
|
||||
|
||||
formats = []
|
||||
|
|
|
@ -14,7 +14,6 @@ from datetime import datetime, timedelta
|
|||
def is_dst(date):
|
||||
year = date.year
|
||||
# last sunday of march and october, respectively. might break on switch days.
|
||||
# but if they meet on a sunday, we probably got bigger problems than videos, right?
|
||||
dst_start = datetime(year, 3, 31, 2) - timedelta(days=(datetime(year, 3, 31).weekday() + 1) % 7)
|
||||
dst_end = datetime(year, 10, 31, 3) - timedelta(days=(datetime(year, 10, 31).weekday() + 1) % 7)
|
||||
return dst_start <= date <= dst_end
|
||||
|
|
Loading…
Reference in New Issue
Block a user