mirror of
https://github.com/zulip/zulip.git
synced 2025-11-01 20:44:04 +00:00
ruff: Fix N818 exception name should be named with an Error suffix.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
committed by
Tim Abbott
parent
eb2c822d3f
commit
73c4da7974
@@ -4,7 +4,7 @@ import string
|
||||
from django.http import HttpRequest, HttpResponse
|
||||
|
||||
from zerver.decorator import webhook_view
|
||||
from zerver.lib.exceptions import UnsupportedWebhookEventType
|
||||
from zerver.lib.exceptions import UnsupportedWebhookEventTypeError
|
||||
from zerver.lib.request import REQ, has_request_variables
|
||||
from zerver.lib.response import json_success
|
||||
from zerver.lib.validator import WildValue, check_string, to_wild_value
|
||||
@@ -47,7 +47,7 @@ def api_basecamp_webhook(
|
||||
event = get_event_type(payload)
|
||||
|
||||
if event not in SUPPORT_EVENTS:
|
||||
raise UnsupportedWebhookEventType(event)
|
||||
raise UnsupportedWebhookEventTypeError(event)
|
||||
|
||||
subject = get_project_name(payload)
|
||||
if event.startswith("document_"):
|
||||
@@ -72,7 +72,7 @@ def api_basecamp_webhook(
|
||||
body = get_comment_body(event, payload)
|
||||
event = "comment"
|
||||
else:
|
||||
raise UnsupportedWebhookEventType(event)
|
||||
raise UnsupportedWebhookEventTypeError(event)
|
||||
|
||||
check_send_webhook_message(request, user_profile, subject, body, event)
|
||||
return json_success(request)
|
||||
|
||||
Reference in New Issue
Block a user