diff --git a/CHANGELOG.md b/CHANGELOG.md index b204d4a..f0fd5a2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,7 +4,7 @@ Fixes: - add possibility to use the same meeting ID for two different secrets. -- send an error if meeting id is too long (2 < id_length < 100 chars) +- return an error message if meeting id is out of range (2 <= id_length <= 100 chars) ## 3.2.2 - 2024-05-23 diff --git a/b3lb/rest/classes/api.py b/b3lb/rest/classes/api.py index a495e13..9f01705 100644 --- a/b3lb/rest/classes/api.py +++ b/b3lb/rest/classes/api.py @@ -116,10 +116,10 @@ async def create(self) -> HttpResponse: if not self.meeting_id: return HttpResponse(cst.RETURN_STRING_MISSING_MEETING_ID, content_type=cst.CONTENT_TYPE) - if not 2 <= len(self.meeting_id) < cst.MEETING_ID_LENGTH: + if not 2 <= len(self.meeting_id) <= cst.MEETING_ID_LENGTH: return HttpResponse(cst.RETURN_STRING_MISSING_MEETING_ID_TO_LONG, content_type=cst.CONTENT_TYPE) - if not 2 <= len(self.meeting_name) < cst.MEETING_NAME_LENGTH: + if not 2 <= len(self.meeting_name) <= cst.MEETING_NAME_LENGTH: return HttpResponse(cst.RETURN_STRING_WRONG_MEETING_NAME_LENGTH, content_type=cst.CONTENT_TYPE) if not await self.is_meeting():