make sure we send all the data
This commit is contained in:
parent
52df289230
commit
66492ff40a
@ -31,7 +31,9 @@ class Controller(object):
|
||||
self.handler.end_headers()
|
||||
if type(content) == str:
|
||||
content = content.encode()
|
||||
self.handler.wfile.write(content)
|
||||
while len(content):
|
||||
w = self.handler.wfile.write(content)
|
||||
content = content[w:]
|
||||
|
||||
def send_redirect(self, location, code=303):
|
||||
self.handler.send_response(code)
|
||||
|
Loading…
Reference in New Issue
Block a user