mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-12-06 17:32:31 -05:00
Include status code in APIError and handle APIError in the loop (#4995)
This commit is contained in:
@@ -766,6 +766,13 @@ class Streams(commands.Cog):
|
||||
|
||||
stream.messages.clear()
|
||||
await self.save_streams()
|
||||
except APIError as e:
|
||||
log.error(
|
||||
"Something went wrong whilst trying to contact the stream service's API.\n"
|
||||
"Raw response data:\n%r",
|
||||
e,
|
||||
)
|
||||
continue
|
||||
else:
|
||||
if stream.messages:
|
||||
continue
|
||||
|
||||
Reference in New Issue
Block a user