Handle a case where AvailableDrops returns no campaigns
This commit is contained in:
1 parent
163a056b33
commit
f990aeea38
1 file changed
+1
-1
+1
-1
@@ -261,7 +261,7 @@ class Channel:
|
|||||||
)
|
)
|
||||||
stream.drops_enabled = any(
|
stream.drops_enabled = any(
|
||||||
bool(c["timeBasedDrops"])
|
bool(c["timeBasedDrops"])
|
||||||
for c in available_drops["data"]["channel"]["viewerDropCampaigns"]
|
for c in (available_drops["data"]["channel"]["viewerDropCampaigns"] or [])
|
||||||
)
|
)
|
||||||
return stream
|
return stream
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user