From dcfb6a28926b303f283356e8dcb22625b48ed05e Mon Sep 17 00:00:00 2001 From: Deadswitch Date: Tue, 11 Jan 2022 19:58:56 -0600 Subject: [PATCH] get rid of telegram sending - not compatible with threading --- api1.py | 6 +++--- session.session | Bin 28672 -> 28672 bytes 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/api1.py b/api1.py index 6669cef..b0a5cfc 100644 --- a/api1.py +++ b/api1.py @@ -26,7 +26,7 @@ class Config(object): SCHEDULER_API_ENABLED = True -def sendSelfTelegram(text): +def sendSelfTelegram(message): print(f"sending telegram message to myself") # get your api_id, api_hash, token # from telegram as described above @@ -53,7 +53,7 @@ def sendSelfTelegram(text): client.sign_in(phone, input('Enter the code: ')) try: schlingelId=5070349790 - client.send_message(schlingelId, "test message", parse_mode='html') + client.send_message(schlingelId, message, parse_mode='html') except Exception as e: # there may be many error coming in while like peer # error, wwrong access_hash, flood_error, etc @@ -74,7 +74,7 @@ def sendMail(topic,toAddr): https://deadswitch.kawomi.com/api/v1?topic={topic} """ - sendSelfTelegram(message) + #sendSelfTelegram(message) server.sendmail(sender_email, receiver_email, message) def expiryCheck(): diff --git a/session.session b/session.session index 5cbde987b824a96d55b0eea49b76921add555a5f..2655107d711530b040113b1e9a8831a71ef7d197 100644 GIT binary patch delta 19 acmZp8z}WDBae_3X?nD`9M%|4G3-SR+I|kYS delta 19 acmZp8z}WDBae_3X_Cy(HM(vFW3-SR+9R}6_