1
0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2025-10-30 22:25:19 +00:00

[cleanup] Use format_field where applicable

This commit is contained in:
pukkandan
2022-01-21 13:27:40 +05:30
parent 0bfc53d05c
commit e0ddbd02bd
26 changed files with 59 additions and 52 deletions

View File

@@ -6,6 +6,7 @@ import re
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 @@ class JojIE(InfoExtractor):
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: