mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2025-09-03 00:25:08 +00:00
[cleanup] Use format_field where applicable
This commit is contained in:
@ -2,7 +2,7 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from .common import InfoExtractor
|
||||
from ..utils import float_or_none, int_or_none
|
||||
from ..utils import format_field, float_or_none, int_or_none
|
||||
|
||||
|
||||
class ZhihuIE(InfoExtractor):
|
||||
@ -61,7 +61,7 @@ class ZhihuIE(InfoExtractor):
|
||||
'uploader': author.get('name'),
|
||||
'timestamp': int_or_none(zvideo.get('published_at')),
|
||||
'uploader_id': author.get('id'),
|
||||
'uploader_url': 'https://www.zhihu.com/people/' + url_token if url_token else None,
|
||||
'uploader_url': format_field(url_token, template='https://www.zhihu.com/people/%s'),
|
||||
'duration': float_or_none(video.get('duration')),
|
||||
'view_count': int_or_none(zvideo.get('play_count')),
|
||||
'like_count': int_or_none(zvideo.get('liked_count')),
|
||||
|
Reference in New Issue
Block a user