diff options
| author | 2020-02-25 22:57:52 +0100 | |
|---|---|---|
| committer | 2020-02-25 22:57:52 +0100 | |
| commit | 1f82ed36f24f2ffbef5b3601fb6c11db28735c71 (patch) | |
| tree | 09e5ab1e820cd5037b76c476d910b41db47302b7 | |
| parent | Fix `__iter__` for classes without subsections. (diff) | |
Restyle if body to include the error instead of adding the cog.
| -rw-r--r-- | bot/cogs/reddit.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/bot/cogs/reddit.py b/bot/cogs/reddit.py index e93e4de0c..3278363ba 100644 --- a/bot/cogs/reddit.py +++ b/bot/cogs/reddit.py @@ -290,7 +290,7 @@ class Reddit(Cog): def setup(bot: Bot) -> None: """Load the Reddit cog.""" - if None not in (RedditConfig.client_id, RedditConfig.secret): - bot.add_cog(Reddit(bot)) + if None in (RedditConfig.client_id, RedditConfig.secret): + log.error("Credentials not provided, cog not loaded.") return - log.error("Credentials not provided, cog not loaded.") + bot.add_cog(Reddit(bot)) |