🎨 添加警告

This commit is contained in:
KimigaiiWuyi 2024-05-16 04:48:16 +08:00
parent d5586e420b
commit 11b53e5547
2 changed files with 3 additions and 1 deletions

View File

@ -645,7 +645,7 @@ class Character:
zf = self.power_list['A霜华矢·霜华绽发伤害']
v2 = int(zf['value'][index][:-1])
v1 = int(i[:-1])
val.append(f'{v1 +v2}%')
val.append(f'{v1 + v2}%')
self.power_list[power_name] = {
'name': power_name,

View File

@ -31,6 +31,8 @@ async def import_gachalogs(history_url: str, type: str, uid: str) -> str:
history_data = json.loads(data_bytes.decode())
except UnicodeDecodeError:
history_data = json.loads(data_bytes.decode('gbk'))
except json.decoder.JSONDecodeError:
return '请传入正确的JSON格式文件!'
if 'info' in history_data and 'uid' in history_data['info']:
data_uid = history_data['info']['uid']
if data_uid != uid: