mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 21:43:21 +00:00
python: Elide unnecessary list wrappers.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
committed by
Tim Abbott
parent
eff0a73925
commit
2665a3ce2b
@@ -526,7 +526,7 @@ def get_event(request: HttpRequest, payload: WildValue, branches: Optional[str])
|
||||
if branches.find(branch) == -1:
|
||||
return None
|
||||
|
||||
if event in list(EVENT_FUNCTION_MAPPER.keys()):
|
||||
if event in EVENT_FUNCTION_MAPPER:
|
||||
return event
|
||||
|
||||
raise UnsupportedWebhookEventTypeError(event)
|
||||
|
||||
Reference in New Issue
Block a user