diff options
author | Mark Haines <mark.haines@matrix.org> | 2015-01-23 13:21:58 +0000 |
---|---|---|
committer | Mark Haines <mark.haines@matrix.org> | 2015-01-23 13:21:58 +0000 |
commit | ada711504efb4dd25fe1123d38a0b2d196b9890a (patch) | |
tree | 73789e6eb42442559a7d1e34385827b7465f580c /synapse/handlers/directory.py | |
parent | Replace hs.parse_roomid with RoomID.from_string (diff) | |
download | synapse-ada711504efb4dd25fe1123d38a0b2d196b9890a.tar.xz |
Replace hs.parse_roomalias with RoomAlias.from_string
Diffstat (limited to 'synapse/handlers/directory.py')
-rw-r--r-- | synapse/handlers/directory.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/synapse/handlers/directory.py b/synapse/handlers/directory.py index 91fceda2ac..58e9a91562 100644 --- a/synapse/handlers/directory.py +++ b/synapse/handlers/directory.py @@ -19,6 +19,7 @@ from ._base import BaseHandler from synapse.api.errors import SynapseError, Codes, CodeMessageException from synapse.api.constants import EventTypes +from synapse.types import RoomAlias import logging @@ -122,7 +123,7 @@ class DirectoryHandler(BaseHandler): @defer.inlineCallbacks def on_directory_query(self, args): - room_alias = self.hs.parse_roomalias(args["room_alias"]) + room_alias = RoomAlias.from_string(args["room_alias"]) if not self.hs.is_mine(room_alias): raise SynapseError( 400, "Room Alias is not hosted on this Home Server" |