From ce89a012888dff9f1fff6479a92d9e1fe44afcf4 Mon Sep 17 00:00:00 2001 From: yumoqing Date: Tue, 23 Sep 2025 10:32:28 +0800 Subject: [PATCH] bugfix --- ahserver/filestorage.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ahserver/filestorage.py b/ahserver/filestorage.py index 7ad477a..2ab6768 100644 --- a/ahserver/filestorage.py +++ b/ahserver/filestorage.py @@ -188,8 +188,8 @@ async def downloadfile(url, headers=None, params=None, data={}): fpath = fs._name2path(filename, userid='tmp') try: shc = StreamHttpClient() - async for chunk in shc('GET', url, - async with aiofiles.open(fpath,'wb') as f: + async with aiofiles.open(fpath,'wb') as f: + async for chunk in shc('GET', url, headers=headers, params=params, data=data):