aboutsummaryrefslogtreecommitdiffstats
path: root/youtube/watch.py
diff options
context:
space:
mode:
authorJames Taylor <user234683@users.noreply.github.com>2018-10-01 17:57:31 -0700
committerJames Taylor <user234683@users.noreply.github.com>2018-10-01 17:58:35 -0700
commit03f5ccbacb92313efa709aa8c07f9c1514edf504 (patch)
treec5c4b959d51be394c47f8739702ccfdff537589b /youtube/watch.py
parent6c61472dafbfb0388a3c8c42a46afbd81a50569f (diff)
downloadyt-local-03f5ccbacb92313efa709aa8c07f9c1514edf504.tar.lz
yt-local-03f5ccbacb92313efa709aa8c07f9c1514edf504.tar.xz
yt-local-03f5ccbacb92313efa709aa8c07f9c1514edf504.zip
add support for lc parameter
Diffstat (limited to 'youtube/watch.py')
-rw-r--r--youtube/watch.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/youtube/watch.py b/youtube/watch.py
index d238b2f..6ed0878 100644
--- a/youtube/watch.py
+++ b/youtube/watch.py
@@ -223,10 +223,12 @@ music_list_table_row = Template('''<tr>
<td>$value</td>
''')
def get_watch_page(query_string):
- id = urllib.parse.parse_qs(query_string)['v'][0]
+ parsed_qs = urllib.parse.parse_qs(query_string)
+ id = parsed_qs['v'][0]
+ lc = common.default_multi_get(parsed_qs, 'lc', 0, default='')
downloader = YoutubeDL(params={'youtube_include_dash_manifest':False})
tasks = (
- gevent.spawn(comments.video_comments, id, int(settings.default_comment_sorting) ),
+ gevent.spawn(comments.video_comments, id, int(settings.default_comment_sorting), lc=lc ),
gevent.spawn(extract_info, downloader, "https://www.youtube.com/watch?v=" + id, download=False)
)
gevent.joinall(tasks)