mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-08-06 10:54:12 -04:00
Separate out the matrix http client completely because just about all of its code it now separate from the simple case we need for standard HTTP(S)
This commit is contained in:
parent
20326054da
commit
e377d33652
8 changed files with 362 additions and 338 deletions
|
@ -99,8 +99,12 @@ class LoginHandler(BaseHandler):
|
|||
def _query_email(self, email):
|
||||
httpCli = SimpleHttpClient(self.hs)
|
||||
data = yield httpCli.get_json(
|
||||
'matrix.org:8090', # TODO FIXME This should be configurable.
|
||||
"/_matrix/identity/api/v1/lookup?medium=email&address=" +
|
||||
"%s" % urllib.quote(email)
|
||||
# TODO FIXME This should be configurable.
|
||||
# XXX: ID servers need to use HTTPS
|
||||
"http://%s%s" % ("matrix.org:8090", "/_matrix/identity/api/v1/lookup"),
|
||||
{
|
||||
'medium': 'email',
|
||||
'address': email
|
||||
}
|
||||
)
|
||||
defer.returnValue(data)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue