Browse Source

[periscope] Update uploader_id (Closes #9565)

totalwebcasting
Sergey M․ 9 years ago
parent
commit
92d221ad48
No known key found for this signature in database GPG Key ID: 2C393E0F18A9236D
1 changed files with 5 additions and 2 deletions
  1. +5
    -2
      youtube_dl/extractor/periscope.py

+ 5
- 2
youtube_dl/extractor/periscope.py View File

@ -45,8 +45,11 @@ class PeriscopeIE(InfoExtractor):
broadcast = broadcast_data['broadcast']
status = broadcast['status']
uploader = broadcast.get('user_display_name') or broadcast_data.get('user', {}).get('display_name')
uploader_id = broadcast.get('user_id') or broadcast_data.get('user', {}).get('id')
user = broadcast_data.get('user', {})
uploader = broadcast.get('user_display_name') or user.get('display_name')
uploader_id = (broadcast.get('username') or user.get('username') or
broadcast.get('user_id') or user.get('id'))
title = '%s - %s' % (uploader, status) if uploader else status
state = broadcast.get('state').lower()


Loading…
Cancel
Save