Fixed exception handling with brother database
This commit is contained in:
+1
-1
@@ -117,7 +117,7 @@ async def lookup_slackid_brother(slack_id: str) -> scroll_util.Brother:
|
||||
try:
|
||||
scroll = db[slack_id]
|
||||
return scroll_util.find_by_scroll(scroll)
|
||||
except ValueError:
|
||||
except (KeyError, ValueError):
|
||||
raise scroll_util.BrotherNotFound("Slack id {} not tied to brother".format(slack_id))
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user