aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Hedy Li <[email protected]>2020-10-08 03:36:35 +0000
committerGravatar Hedy Li <[email protected]>2020-10-08 03:36:35 +0000
commitff9abdaad65000ef8b56ed21e58bca2ac227773e (patch)
tree7bcf9ab42f3fcb88b38c0fb3faad8f7ec9703200
parentreturn instead of return boolean (diff)
refactor if else
-rw-r--r--bot/exts/halloween/hacktoberstats.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/bot/exts/halloween/hacktoberstats.py b/bot/exts/halloween/hacktoberstats.py
index fc66bfa8..4f4ea122 100644
--- a/bot/exts/halloween/hacktoberstats.py
+++ b/bot/exts/halloween/hacktoberstats.py
@@ -267,10 +267,9 @@ class HacktoberStats(commands.Cog):
# Ignore logging non-existent users or users we do not have permission to see
if api_message == GITHUB_NONEXISTENT_USER_MESSAGE:
logging.debug(f"No GitHub user found named '{github_username}'")
- return
else:
logging.error(f"GitHub API request for '{github_username}' failed with message: {api_message}")
- return
+ return
if jsonresp["total_count"] == 0:
# Short circuit if there aren't any PRs