diff --git a/utils/Ntfy.py b/utils/Ntfy.py index 9f526df..08b6f66 100644 --- a/utils/Ntfy.py +++ b/utils/Ntfy.py @@ -3,6 +3,9 @@ import requests class ntfy: @classmethod def sendMsg(cls, msg): - print(f"#ntfy: {msg}") - requests.post("https://ntfy.caiwenxiu.cn/PyComic", - data=msg.encode(encoding='utf-8')) \ No newline at end of file + try: + print(f"#ntfy: {msg}") + requests.post("https://ntfy.caiwenxiu.cn/PyComic", + data=msg.encode(encoding='utf-8')) + except: + print(f"#ntfy error: {msg}") \ No newline at end of file