]> jfr.im git - yt-dlp.git/blobdiff - yt_dlp/extractor/joj.py
[cleanup] Use format_field where applicable
[yt-dlp.git] / yt_dlp / extractor / joj.py
index 63761818350b764742a3f8057f11d0e8f350fb6e..7350f537c6c9432f15cc0067388946de417835d6 100644 (file)
@@ -6,6 +6,7 @@
 from .common import InfoExtractor
 from ..compat import compat_str
 from ..utils import (
+    format_field,
     int_or_none,
     js_to_json,
     try_get,
@@ -72,7 +73,7 @@ def _real_extract(self, url):
                     r'(\d+)[pP]\.', format_url, 'height', default=None)
                 formats.append({
                     'url': format_url,
-                    'format_id': '%sp' % height if height else None,
+                    'format_id': format_field(height, template='%sp'),
                     'height': int(height),
                 })
         if not formats: