Skip to content

Commit 48d3e2d

Browse files
fix: typo in exception handling
This probably was due to an oversight during refactoring.
1 parent 7ad6d3c commit 48d3e2d

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/webview/suggestions/views/maintainers.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def post(
2929
suggestion, suggestion_context = (
3030
self._check_access_rights_and_get_suggestion(request, suggestion_id)
3131
)
32-
except self.AccessDeniedError as e:
32+
except self.ForbiddenOperationError as e:
3333
return e.response
3434

3535
# Validate the requested operation
@@ -288,7 +288,7 @@ def post(self, request: HttpRequest, suggestion_id: int) -> HttpResponse:
288288
suggestion, suggestion_context = (
289289
self._check_access_rights_and_get_suggestion(request, suggestion_id)
290290
)
291-
except self.AccessDeniedError as e:
291+
except self.ForbiddenOperationError as e:
292292
return e.response
293293

294294
# Validate the provided handle

src/webview/suggestions/views/packages.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def post(
3131
suggestion, suggestion_context = (
3232
self._check_access_rights_and_get_suggestion(request, suggestion_id)
3333
)
34-
except self.AccessDeniedError as e:
34+
except self.ForbiddenOperationError as e:
3535
return e.response
3636

3737
# Validate that the package exists in the suggestion

0 commit comments

Comments
 (0)