Fix clip download due to missing fields in query

fixes #45
This commit is contained in:
Ivan Habunek 2020-11-23 15:40:33 +01:00
parent 6108b15587
commit cf8d13e80e
No known key found for this signature in database
GPG Key ID: CDBD63C43A30BB95

View File

@ -74,7 +74,9 @@ def get_clip(slug):
query = """ query = """
{{ {{
clip(slug: "{}") {{ clip(slug: "{}") {{
id
title title
createdAt
durationSeconds durationSeconds
game {{ game {{
name name
@ -82,6 +84,9 @@ def get_clip(slug):
broadcaster {{ broadcaster {{
login login
displayName displayName
channel {{
name
}}
}} }}
videoQualities {{ videoQualities {{
frameRate frameRate
@ -153,7 +158,6 @@ def get_channel_clips(channel_id, period, limit, after=None):
"period": period.upper(), "period": period.upper(),
}) })
response = gql_query(query) response = gql_query(query)
user = response["data"]["user"] user = response["data"]["user"]
if not user: if not user: