aboutsummaryrefslogtreecommitdiff
path: root/yt_dlp/extractor/snapchat.py
diff options
context:
space:
mode:
authorsepro <sepro@sepr0.com>2024-11-04 01:33:21 +0100
committerGitHub <noreply@github.com>2024-11-04 01:33:21 +0100
commit197d0b03b6a3c8fe4fa5ace630eeffec629bf72c (patch)
tree577bda6784f8c1dbd9bcdf5e3a524a3c3c650f75 /yt_dlp/extractor/snapchat.py
parentb03267bf0675eeb8df5baf1daac7cf67840c91a5 (diff)
[cleanup] Misc (#11347)
Closes #11361 Authored by: avagordon01, bashonly, grqz, Grub4K, seproDev Co-authored-by: Ava Gordon <avagordon01@gmail.com> Co-authored-by: bashonly <bashonly@protonmail.com> Co-authored-by: N/Ame <173015200+grqz@users.noreply.github.com> Co-authored-by: Simon Sawicki <contact@grub4k.xyz>
Diffstat (limited to 'yt_dlp/extractor/snapchat.py')
-rw-r--r--yt_dlp/extractor/snapchat.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/yt_dlp/extractor/snapchat.py b/yt_dlp/extractor/snapchat.py
index 732677c19..09e5766d4 100644
--- a/yt_dlp/extractor/snapchat.py
+++ b/yt_dlp/extractor/snapchat.py
@@ -56,13 +56,13 @@ class SnapchatSpotlightIE(InfoExtractor):
**traverse_obj(video_data, ('videoMetadata', {
'title': ('name', {str}),
'description': ('description', {str}),
- 'timestamp': ('uploadDateMs', {lambda x: float_or_none(x, 1000)}),
+ 'timestamp': ('uploadDateMs', {float_or_none(scale=1000)}),
'view_count': ('viewCount', {int_or_none}, {lambda x: None if x == -1 else x}),
'repost_count': ('shareCount', {int_or_none}),
'url': ('contentUrl', {url_or_none}),
'width': ('width', {int_or_none}),
'height': ('height', {int_or_none}),
- 'duration': ('durationMs', {lambda x: float_or_none(x, 1000)}),
+ 'duration': ('durationMs', {float_or_none(scale=1000)}),
'thumbnail': ('thumbnailUrl', {url_or_none}),
'uploader': ('creator', 'personCreator', 'username', {str}),
'uploader_url': ('creator', 'personCreator', 'url', {url_or_none}),