mirror of
https://git.anonymousland.org/anonymousland/synapse-product.git
synced 2025-08-07 12:52:13 -04:00
Merge remote-tracking branch 'upstream/release-v1.48'
This commit is contained in:
commit
9f4fa40b64
175 changed files with 6413 additions and 1993 deletions
|
@ -206,6 +206,10 @@ class DirectoryHandler:
|
|||
)
|
||||
|
||||
room_id = await self._delete_association(room_alias)
|
||||
if room_id is None:
|
||||
# It's possible someone else deleted the association after the
|
||||
# checks above, but before we did the deletion.
|
||||
raise NotFoundError("Unknown room alias")
|
||||
|
||||
try:
|
||||
await self._update_canonical_alias(requester, user_id, room_id, room_alias)
|
||||
|
@ -227,7 +231,7 @@ class DirectoryHandler:
|
|||
)
|
||||
await self._delete_association(room_alias)
|
||||
|
||||
async def _delete_association(self, room_alias: RoomAlias) -> str:
|
||||
async def _delete_association(self, room_alias: RoomAlias) -> Optional[str]:
|
||||
if not self.hs.is_mine(room_alias):
|
||||
raise SynapseError(400, "Room alias must be local")
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue