diff options
| author | 2019-02-08 21:56:58 +0000 | |
|---|---|---|
| committer | 2019-02-08 21:56:58 +0000 | |
| commit | 4a68baa0a6c47ede108c44e69a07e23e256ffbea (patch) | |
| tree | b15ee940a8075bec00100581bea30c96daeb26a3 | |
| parent | Typo, 'utils.parse' -> 'urllib.parse' (rest_api.py) (diff) | |
| signature | ||
Return `path` from `_path_data()` (rest_api.py)
| -rw-r--r-- | modules/rest_api.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/rest_api.py b/modules/rest_api.py index 2bdcb254..a3bab0b5 100644 --- a/modules/rest_api.py +++ b/modules/rest_api.py @@ -15,7 +15,7 @@ class Handler(http.server.BaseHTTPRequestHandler): _, _, endpoint = path[1:].partition("/") endpoint, _, args = endpoint.partition("/") args = list(filter(None, args.split("/"))) - return endpoint, args + return path, endpoint, args def _url_params(self): parsed = urllib.parse.urlparse(self.path) @@ -27,7 +27,7 @@ class Handler(http.server.BaseHTTPRequestHandler): return self.rfile.read(content_length) def _handle(self, method): - endpoint, args = self._path_data() + path, endpoint, args = self._path_data() headers = utils.CaseInsensitiveDict(dict(self.headers.items())) params = self._url_params() data = self._body() |
