Allow creating too long aliases

This commit is contained in:
Tulir Asokan 2022-08-28 11:35:26 +03:00
parent f199fbf45d
commit 395a57110f

View File

@ -117,7 +117,10 @@ class DirectoryHandler:
user_id = requester.user.to_string()
room_alias_str = room_alias.to_string()
if len(room_alias_str) > MAX_ALIAS_LENGTH:
if (
user_id not in self.hs.config.meow.validation_override
and len(room_alias_str) > MAX_ALIAS_LENGTH
):
raise SynapseError(
400,
"Can't create aliases longer than %s characters" % MAX_ALIAS_LENGTH,