aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpukkandan <pukkandan@users.noreply.github.com>2021-01-07 20:50:45 +0530
committerpukkandan <pukkandan@gmail.com>2021-01-07 20:53:03 +0530
commit9d88274ca2e5248481204e753b458e3a4eeac60e (patch)
tree27b312678d5eb1bed87ebb0af9f453fbfa94a424
parent7dbce2c53266ebedc824d4263b08911770234c35 (diff)
parent61e76c1e5fc6df3ebb4f728c5cc999349d36c55d (diff)
downloadhypervideo-pre-9d88274ca2e5248481204e753b458e3a4eeac60e.tar.lz
hypervideo-pre-9d88274ca2e5248481204e753b458e3a4eeac60e.tar.xz
hypervideo-pre-9d88274ca2e5248481204e753b458e3a4eeac60e.zip
Tiktok fix #8 (blackjack4494#20)
Authored by GreyAlien502
-rw-r--r--youtube_dlc/extractor/tiktok.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/youtube_dlc/extractor/tiktok.py b/youtube_dlc/extractor/tiktok.py
index 0cfd2168a..0f2b4acae 100644
--- a/youtube_dlc/extractor/tiktok.py
+++ b/youtube_dlc/extractor/tiktok.py
@@ -133,6 +133,8 @@ class TikTokIE(TikTokBaseIE):
def _real_extract(self, url):
video_id = self._match_id(url)
+ # If we only call once, we get a 403 when downlaoding the video.
+ self._download_webpage(url, video_id)
webpage = self._download_webpage(url, video_id, note='Downloading video webpage')
json_string = self._search_regex(
r'id=\"__NEXT_DATA__\"\s+type=\"application\/json\"\s*[^>]+>\s*(?P<json_string_ld>[^<]+)',