Merge branch 'dev' of https://github.com/MaiM-with-u/MaiBot into dev
This commit is contained in:
@@ -309,7 +309,11 @@ async def clear_temp_emoji() -> None:
|
||||
|
||||
logger.info("[清理] 开始清理缓存...")
|
||||
|
||||
for need_clear in (os.path.join(BASE_DIR, "emoji"), os.path.join(BASE_DIR, "image"), os.path.join(BASE_DIR, "images")):
|
||||
for need_clear in (
|
||||
os.path.join(BASE_DIR, "emoji"),
|
||||
os.path.join(BASE_DIR, "image"),
|
||||
os.path.join(BASE_DIR, "images"),
|
||||
):
|
||||
if os.path.exists(need_clear):
|
||||
files = os.listdir(need_clear)
|
||||
# 如果文件数超过100就全部删除
|
||||
|
||||
@@ -148,9 +148,7 @@ class ExpressionSelector:
|
||||
expr["count"] = new_count
|
||||
expr["last_active_time"] = time.time()
|
||||
|
||||
logger.info(
|
||||
f"表达方式激活: 原count={current_count:.2f}, 增量={increment}, 新count={new_count:.2f}"
|
||||
)
|
||||
logger.info(f"表达方式激活: 原count={current_count:.2f}, 增量={increment}, 新count={new_count:.2f}")
|
||||
break
|
||||
|
||||
# 保存更新后的文件
|
||||
|
||||
Reference in New Issue
Block a user