1
0
Fork 0

[cleanup] Use format_field where applicable

This commit is contained in:
pukkandan 2022-01-21 13:27:40 +05:30
commit e0ddbd02bd
No known key found for this signature in database
GPG key ID: 0F00D95A001F4698
26 changed files with 59 additions and 52 deletions

View file

@ -7,6 +7,7 @@ from ..compat import (
)
from ..utils import (
ExtractorError,
format_field,
int_or_none,
qualities,
)
@ -95,7 +96,7 @@ class FlickrIE(InfoExtractor):
owner = video_info.get('owner', {})
uploader_id = owner.get('nsid')
uploader_path = owner.get('path_alias') or uploader_id
uploader_url = 'https://www.flickr.com/photos/%s/' % uploader_path if uploader_path else None
uploader_url = format_field(uploader_path, template='https://www.flickr.com/photos/%s/')
return {
'id': video_id,