diff --git a/site/app.py b/site/app.py index 73b72a5..e26e30c 100644 --- a/site/app.py +++ b/site/app.py @@ -29,6 +29,8 @@ def ws_upload(ws): chunk = ws.receive() if chunk is None: break + if isinstance(chunk, str) and chunk == 'DONE': + break total += len(chunk) elapsed = round((time.time() - t0) * 1000) ws.send(json.dumps({'ok': True, 'bytes': total, 'elapsed_ms': elapsed}))