logo

youtube-dl

[mirror] Download/Watch videos from video hostersgit clone https://hacktivis.me/git/mirror/youtube-dl.git
commit: 679b711395c2d6a75b376e8f7b8b2529669c4c27
parent 172754131578f6042efa7c47a57c6e8531e3d190
Author: Sergey M․ <dstftw@gmail.com>
Date:   Sun, 13 Dec 2020 20:27:08 +0700

[eporner] Fix view count extraction and make optional (closes #23306)

Diffstat:

Myoutube_dl/extractor/eporner.py4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/youtube_dl/extractor/eporner.py b/youtube_dl/extractor/eporner.py @@ -118,8 +118,8 @@ class EpornerIE(InfoExtractor): duration = parse_duration(self._html_search_meta( 'duration', webpage, default=None)) view_count = str_to_int(self._search_regex( - r'id="cinemaviews">\s*([0-9,]+)\s*<small>views', - webpage, 'view count', fatal=False)) + r'id=["\']cinemaviews1["\'][^>]*>\s*([0-9,]+)', + webpage, 'view count', default=None)) return merge_dicts(json_ld, { 'id': video_id,