mirror of
https://github.com/whyour/qinglong.git
synced 2026-06-01 11:20:14 +08:00
Fix HITOKOTO parameter boolean/string type handling (#2918)
* Initial plan * Fix HITOKOTO parameter type mismatch in notify scripts Co-authored-by: whyour <22700758+whyour@users.noreply.github.com> * Refactor JavaScript HITOKOTO check for consistency with Python Co-authored-by: whyour <22700758+whyour@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: whyour <22700758+whyour@users.noreply.github.com>
This commit is contained in:
parent
e06c3571a8
commit
0e5b8bef4b
|
|
@ -1582,7 +1582,7 @@ async function sendNotify(text, desp, params = {}) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (push_config.HITOKOTO !== 'false') {
|
if (![false, 'false'].includes(push_config.HITOKOTO)) {
|
||||||
desp += '\n\n' + (await one());
|
desp += '\n\n' + (await one());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1131,7 +1131,7 @@ def send(title: str, content: str, ignore_default_config: bool = False, **kwargs
|
||||||
return
|
return
|
||||||
|
|
||||||
hitokoto = push_config.get("HITOKOTO")
|
hitokoto = push_config.get("HITOKOTO")
|
||||||
content += "\n\n" + one() if hitokoto != "false" else ""
|
content += "\n\n" + one() if hitokoto not in [False, "false"] else ""
|
||||||
|
|
||||||
notify_function = add_notify_function()
|
notify_function = add_notify_function()
|
||||||
ts = [
|
ts = [
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user