don't spam the log if the network is failing

master
anon_user 2019-09-15 07:30:50 +02:00
parent bae6836800
commit c2df1d83f8
1 changed files with 2 additions and 0 deletions

View File

@ -25,6 +25,8 @@ class MastodonBot(Bot):
return mentions
try:
notifications = m.notifications()
except mastodon.MastodonNetworkError:
return mentions
except mastodon.MastodonInternalServerError:
try:
logger.error("Mastodon Error: 500. Server: " + m.instance()['urls']['streaming_api'])