From: JChris246 <43832407+JChris246@users.noreply.github.com>
Date: Sat, 28 Nov 2020 19:32:13 +0000 (-0400)
Subject: [pornhub] Fix like and dislike count extraction (closes #27227) (#27234)
X-Git-Url: http://git.oshgnacknak.de/?a=commitdiff_plain;h=f04cfe24e0554ca7e08db94ef138d44d22493af0;p=youtube-dl
[pornhub] Fix like and dislike count extraction (closes #27227) (#27234)
---
diff --git a/youtube_dl/extractor/pornhub.py b/youtube_dl/extractor/pornhub.py
index 529f3f711..a50b6260c 100644
--- a/youtube_dl/extractor/pornhub.py
+++ b/youtube_dl/extractor/pornhub.py
@@ -346,9 +346,9 @@ class PornHubIE(PornHubBaseIE):
view_count = self._extract_count(
r'([\d,\.]+) [Vv]iews', webpage, 'view')
like_count = self._extract_count(
- r'([\d,\.]+)', webpage, 'like')
+ r']+class="votesUp"[^>]*>([\d,\.]+)', webpage, 'like')
dislike_count = self._extract_count(
- r'([\d,\.]+)', webpage, 'dislike')
+ r']+class="votesDown"[^>]*>([\d,\.]+)', webpage, 'dislike')
comment_count = self._extract_count(
r'All Comments\s*\(([\d,.]+)\)', webpage, 'comment')