summary refs log tree commit diff
path: root/contrib/cmdclient/http.py
diff options
context:
space:
mode:
authorRichard van der Hoff <github@rvanderhoff.org.uk>2017-04-24 15:20:52 +0100
committerGitHub <noreply@github.com>2017-04-24 15:20:52 +0100
commit30f7bfa121fb2f37df5e7783424c3c113200c4d4 (patch)
tree91be8aacc0e9382a0acf3793acde3e2345ba0d6b /contrib/cmdclient/http.py
parentMerge pull request #2155 from matrix-org/erikj/string_intern (diff)
parentTry harder when sending leave events (diff)
downloadsynapse-30f7bfa121fb2f37df5e7783424c3c113200c4d4.tar.xz
Merge pull request #2145 from matrix-org/rav/reject_invite_to_unreachable_server
Fix rejection of invites to unreachable servers
Diffstat (limited to 'contrib/cmdclient/http.py')
-rw-r--r--contrib/cmdclient/http.py16
1 files changed, 6 insertions, 10 deletions
diff --git a/contrib/cmdclient/http.py b/contrib/cmdclient/http.py
index 4186897316..c833f3f318 100644
--- a/contrib/cmdclient/http.py
+++ b/contrib/cmdclient/http.py
@@ -36,15 +36,13 @@ class HttpClient(object):
                 the request body. This will be encoded as JSON.
 
         Returns:
-            Deferred: Succeeds when we get *any* HTTP response.
-
-            The result of the deferred is a tuple of `(code, response)`,
-            where `response` is a dict representing the decoded JSON body.
+            Deferred: Succeeds when we get a 2xx HTTP response. The result
+            will be the decoded JSON body.
         """
         pass
 
     def get_json(self, url, args=None):
-        """ Get's some json from the given host homeserver and path
+        """ Gets some json from the given host homeserver and path
 
         Args:
             url (str): The URL to GET data from.
@@ -54,10 +52,8 @@ class HttpClient(object):
                 and *not* a string.
 
         Returns:
-            Deferred: Succeeds when we get *any* HTTP response.
-
-            The result of the deferred is a tuple of `(code, response)`,
-            where `response` is a dict representing the decoded JSON body.
+            Deferred: Succeeds when we get a 2xx HTTP response. The result
+            will be the decoded JSON body.
         """
         pass
 
@@ -214,4 +210,4 @@ class _JsonProducer(object):
         pass
 
     def stopProducing(self):
-        pass
\ No newline at end of file
+        pass