From d4eac2ae48094457abdda8802810b53ba3c7958a Mon Sep 17 00:00:00 2001 From: Ludwig Reiter Date: Wed, 30 Oct 2024 13:41:17 +0100 Subject: [PATCH] Fix mismatch of perm check of get-forwarding-meetings permissions and error message(#2707) --- openslides_backend/presenter/get_forwarding_meetings.py | 2 +- tests/system/presenter/test_get_forwarding_meetings.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/openslides_backend/presenter/get_forwarding_meetings.py b/openslides_backend/presenter/get_forwarding_meetings.py index 89a5702fa..f3b52b8c5 100644 --- a/openslides_backend/presenter/get_forwarding_meetings.py +++ b/openslides_backend/presenter/get_forwarding_meetings.py @@ -41,7 +41,7 @@ def get_result(self) -> Any: self.data["meeting_id"], ): msg = "You are not allowed to perform presenter get_forwarding_meetings" - msg += f" Missing permission: {Permissions.Motion.CAN_MANAGE}" + msg += f" Missing permission: {Permissions.Motion.CAN_FORWARD}" raise PermissionDenied(msg) meeting = self.datastore.get( diff --git a/tests/system/presenter/test_get_forwarding_meetings.py b/tests/system/presenter/test_get_forwarding_meetings.py index 78984caf2..bd02973aa 100644 --- a/tests/system/presenter/test_get_forwarding_meetings.py +++ b/tests/system/presenter/test_get_forwarding_meetings.py @@ -311,4 +311,4 @@ def test_with_locked_meeting(self) -> None: ) status_code, data = self.request("get_forwarding_meetings", {"meeting_id": 3}) assert status_code == 403 - assert "Missing permission: motion.can_manage" in data["message"] + assert "Missing permission: motion.can_forward" in data["message"]