summaryrefslogtreecommitdiffstats
path: root/yt_dlp/extractor/bongacams.py
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-08-05 09:06:10 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-08-05 09:06:10 +0000
commit137f07c27a88b07df57df5b2cdebebe3c7722bac (patch)
tree4ebdcbea6b540f69c40ba0be6ac766008030d149 /yt_dlp/extractor/bongacams.py
parentAdding debian version 2024.05.27-1. (diff)
downloadyt-dlp-137f07c27a88b07df57df5b2cdebebe3c7722bac.tar.xz
yt-dlp-137f07c27a88b07df57df5b2cdebebe3c7722bac.zip
Merging upstream version 2024.07.01.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'yt_dlp/extractor/bongacams.py')
-rw-r--r--yt_dlp/extractor/bongacams.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/yt_dlp/extractor/bongacams.py b/yt_dlp/extractor/bongacams.py
index bf95566..ab85477 100644
--- a/yt_dlp/extractor/bongacams.py
+++ b/yt_dlp/extractor/bongacams.py
@@ -1,5 +1,4 @@
from .common import InfoExtractor
-from ..compat import compat_str
from ..utils import (
int_or_none,
try_get,
@@ -38,7 +37,7 @@ class BongaCamsIE(InfoExtractor):
channel_id = mobj.group('id')
amf = self._download_json(
- 'https://%s/tools/amf.php' % host, channel_id,
+ f'https://{host}/tools/amf.php', channel_id,
data=urlencode_postdata((
('method', 'getRoomData'),
('args[]', channel_id),
@@ -48,14 +47,14 @@ class BongaCamsIE(InfoExtractor):
server_url = amf['localData']['videoServerUrl']
uploader_id = try_get(
- amf, lambda x: x['performerData']['username'], compat_str) or channel_id
+ amf, lambda x: x['performerData']['username'], str) or channel_id
uploader = try_get(
- amf, lambda x: x['performerData']['displayName'], compat_str)
+ amf, lambda x: x['performerData']['displayName'], str)
like_count = int_or_none(try_get(
amf, lambda x: x['performerData']['loversCount']))
formats = self._extract_m3u8_formats(
- '%s/hls/stream_%s/playlist.m3u8' % (server_url, uploader_id),
+ f'{server_url}/hls/stream_{uploader_id}/playlist.m3u8',
channel_id, 'mp4', m3u8_id='hls', live=True)
return {