[cleanup] Use format_field where applicable
This commit is contained in:
parent
0bfc53d05c
commit
e0ddbd02bd
26 changed files with 59 additions and 52 deletions
|
|
@ -5,6 +5,7 @@ from __future__ import unicode_literals
|
|||
from .common import InfoExtractor
|
||||
from ..compat import compat_str
|
||||
from ..utils import (
|
||||
format_field,
|
||||
int_or_none,
|
||||
js_to_json,
|
||||
str_or_none,
|
||||
|
|
@ -121,7 +122,7 @@ class LineLiveBaseIE(InfoExtractor):
|
|||
'timestamp': int_or_none(item.get('createdAt')),
|
||||
'channel': channel.get('name'),
|
||||
'channel_id': channel_id,
|
||||
'channel_url': 'https://live.line.me/channels/' + channel_id if channel_id else None,
|
||||
'channel_url': format_field(channel_id, template='https://live.line.me/channels/%s'),
|
||||
'duration': int_or_none(item.get('archiveDuration')),
|
||||
'view_count': int_or_none(item.get('viewerCount')),
|
||||
'comment_count': int_or_none(item.get('chatCount')),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue