Skip to content

Commit

Permalink
[cda] Improve birth validation detection (closes #14022) (#27929)
Browse files Browse the repository at this point in the history
Co-authored-by: Sergey M <[email protected]>
  • Loading branch information
knapior and dstftw authored Jan 27, 2021
1 parent fd95fc3 commit 7b8fa65
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion youtube_dl/extractor/cda.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ def _real_extract(self, url):
raise ExtractorError('This video is only available for premium users.', expected=True)

need_confirm_age = False
if self._html_search_regex(r'(<form[^>]+action="/a/validatebirth")',
if self._html_search_regex(r'(<form[^>]+action="[^"]*/a/validatebirth[^"]*")',
webpage, 'birthday validate form', default=None):
webpage = self._download_age_confirm_page(
url, video_id, note='Confirming age')
Expand Down

0 comments on commit 7b8fa65

Please sign in to comment.