mirror of
https://github.com/A-Minos/nonebot-plugin-tetris-stats.git
synced 2026-03-05 05:36:54 +08:00
🐛 修复错误判断问题并优化代码 (#145)
* 修复错误判断问题并优化代码 * 修改成 elif * Update database.py --------- Co-authored-by: scdhh <51957264+shoucandanghehe@users.noreply.github.com>
This commit is contained in:
@@ -82,11 +82,12 @@ class DataBase():
|
||||
|
||||
if result is None:
|
||||
trending = '?'
|
||||
else:
|
||||
if result[0] > trline:
|
||||
trending = '↑'
|
||||
else:
|
||||
trending = '↓'
|
||||
elif trline > result[0]:
|
||||
trending = '↑'
|
||||
elif trline == result[0]:
|
||||
trending = '-'
|
||||
elif trline < result[0]:
|
||||
trending = '↓'
|
||||
|
||||
cursor.execute('''INSERT INTO IORANK
|
||||
(RANK, TRENDING, TRLINE, PLAYERCOUNT, AVGAPM, AVGPPS, ARGVS, DATE)
|
||||
|
||||
Reference in New Issue
Block a user