diff --git a/notify.py b/notify.py index 43fd33f..921b5a3 100644 --- a/notify.py +++ b/notify.py @@ -33,7 +33,7 @@ def print(text, *args, **kw): # 通知服务 # fmt: off push_config = { - 'HITOKOTO': True, # 启用一言(随机句子) + 'HITOKOTO': False, # 启用一言(随机句子) 'BARK_PUSH': '', # bark IP 或设备码,例:https://api.day.app/DxHcxxxxxRxxxxxxcm/ 'BARK_ARCHIVE': '', # bark 推送是否存档 @@ -1020,8 +1020,9 @@ def send(title: str, content: str, ignore_default_config: bool = False, **kwargs print(f"{title} 在SKIP_PUSH_TITLE环境变量内,跳过推送!") return - hitokoto = push_config.get("HITOKOTO", "false") - content += "\n\n" + one() if hitokoto != "false" else "" + hitokoto = push_config.get("HITOKOTO") + if hitokoto and str(hitokoto).lower() != "false": + content += "\n\n" + one() notify_function = add_notify_function() ts = [