fix issue with automatic subtitles being outside the video
This commit is contained in:
parent
cccffb8354
commit
5b8a50c1c4
@ -45,7 +45,9 @@ def youtube(env, start_response):
|
|||||||
return local_playlist.get_playlist_page(path[10:], query_string=query_string).encode()
|
return local_playlist.get_playlist_page(path[10:], query_string=query_string).encode()
|
||||||
elif path.startswith("/api/"):
|
elif path.startswith("/api/"):
|
||||||
start_response('200 OK', () )
|
start_response('200 OK', () )
|
||||||
return common.fetch_url('https://www.youtube.com' + path + ('?' + query_string if query_string else ''))
|
result = common.fetch_url('https://www.youtube.com' + path + ('?' + query_string if query_string else ''))
|
||||||
|
result = result.replace(b"align:start position:0%", b"")
|
||||||
|
return result
|
||||||
else:
|
else:
|
||||||
start_response('404 Not Found', () )
|
start_response('404 Not Found', () )
|
||||||
return b'404 Not Found'
|
return b'404 Not Found'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user