diff options
Diffstat (limited to 'client/src/leap/soledad')
-rw-r--r-- | client/src/leap/soledad/client/_http.py | 25 |
1 files changed, 2 insertions, 23 deletions
diff --git a/client/src/leap/soledad/client/_http.py b/client/src/leap/soledad/client/_http.py index 20e61685..ba6f9a27 100644 --- a/client/src/leap/soledad/client/_http.py +++ b/client/src/leap/soledad/client/_http.py @@ -34,36 +34,15 @@ from leap.common.certs import get_compatible_ssl_context_factory __all__ = ['HTTPClient', 'PinnedTokenAgent'] -class HTTPClient(object): +class HTTPClient(_HTTPClient): def __init__(self, uuid, token, cert_file): self._agent = PinnedTokenAgent(uuid, token, cert_file) - self._client = _HTTPClient(self._agent) + super(self.__class__, self).__init__(self._agent) def set_token(self, token): self._agent.set_token(token) - def head(self, url, **kwargs): - return self._client.head(url, **kwargs) - - def get(self, url, headers=None, **kwargs): - return self._client.get(url, headers=headers, **kwargs) - - def post(self, url, data=None, **kwargs): - return self._client.post(url, data=data, **kwargs) - - def put(self, url, data=None, **kwargs): - return self._client.put(url, data=data, **kwargs) - - def patch(self, url, data=None, **kwargs): - return self._client.patch(url, data=data, **kwargs) - - def delete(self, url, **kwargs): - return self._client.delete(url, **kwargs) - - def request(self, method, url, **kwargs): - return self._client.request(method, url, **kwargs) - @implementer(IAgent) class PinnedTokenAgent(Agent): |