Skip to content

Commit

Permalink
Tiktok fix #8 (blackjack4494#20)
Browse files Browse the repository at this point in the history
Authored by GreyAlien502
  • Loading branch information
pukkandan committed Jan 7, 2021
2 parents 7dbce2c + 61e76c1 commit 9d88274
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions youtube_dlc/extractor/tiktok.py
Original file line number Diff line number Diff line change
Expand Up @@ -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>[^<]+)',
Expand Down

0 comments on commit 9d88274

Please sign in to comment.