From a54b19e2aa8b5534d856b73b02282e68f9b14962 Mon Sep 17 00:00:00 2001 From: wuchangjun233 <34960661+wuchangjun233@users.noreply.github.com> Date: Sat, 22 Apr 2023 12:38:55 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20=E4=BF=AE=E5=A4=8D`onebot=5Fv12`?= =?UTF-8?q?=E6=96=87=E4=BB=B6=E5=8F=91=E9=80=81=E4=B9=B1=E7=A0=81=20(#516)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- GenshinUID/client.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/GenshinUID/client.py b/GenshinUID/client.py index 6665c28f..3a4e8e48 100644 --- a/GenshinUID/client.py +++ b/GenshinUID/client.py @@ -668,11 +668,11 @@ async def onebot_v12_send( await send_file_message(params, "image", file_id) elif file: file_name, file_content = file.split('|') - file_content = base64.b64decode(file) + file_data = base64.b64decode(file_content) up_data = await bot.call_api( 'upload_file', type="data", - data=file_content, + data=file_data, name=f"{file_name}", ) file_id = up_data['file_id']