need to .items()
a dict to tuple-iterate it (rest_api.py)
This commit is contained in:
parent
678e6606ed
commit
d772eaf36e
1 changed files with 1 additions and 1 deletions
|
@ -28,7 +28,7 @@ class Handler(http.server.BaseHTTPRequestHandler):
|
|||
|
||||
def _respond(self, code, headers, data):
|
||||
self.send_response(code)
|
||||
for key, value in headers:
|
||||
for key, value in headers.items():
|
||||
self.send_header(key, value)
|
||||
self.end_headers()
|
||||
self.wfile.write(data.encode("utf8"))
|
||||
|
|
Loading…
Reference in a new issue