From d0007bf6b17ba0f9c51017b13320c314868085e0 Mon Sep 17 00:00:00 2001 From: codeskyblue Date: Tue, 10 Dec 2019 20:15:45 +0800 Subject: [PATCH] fix not working on windows bug, close #67 --- weditor/web/handlers/proxy.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/weditor/web/handlers/proxy.py b/weditor/web/handlers/proxy.py index b290de4..6e020f2 100644 --- a/weditor/web/handlers/proxy.py +++ b/weditor/web/handlers/proxy.py @@ -15,8 +15,8 @@ class StaticProxyHandler(tornado.web.StaticFileHandler): http_client = tornado.httpclient.AsyncHTTPClient() - def initialize(self, path: str ="/", default_filename: str = None) -> None: - self.root = path + def initialize(self, path: str = None, default_filename: str = None) -> None: + self.root = path if path else os.path.expanduser("~") self.default_filename = default_filename async def download_file(self, path: str) -> str: