From 638530106216b7f33c9dc114b3b54dea61c6bdb6 Mon Sep 17 00:00:00 2001 From: Jiting Date: Fri, 15 Feb 2019 19:00:20 +0800 Subject: [PATCH] =?UTF-8?q?fix=20bug=20again...=20=E5=BF=98=E8=AE=B0?= =?UTF-8?q?=E5=90=8C=E6=AD=A5=E6=9B=B4=E6=94=B9=E6=83=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- maker.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/maker.py b/maker.py index 9534833..2b71a01 100644 --- a/maker.py +++ b/maker.py @@ -89,7 +89,7 @@ def telegram_push(string, debug=0): querystring = parse.urlencode({"text": string.encode('utf-8')}) tg_api = os.getenv('TG_API') group_id = os.getenv('TG_GROUP_ID') - if tg_api == "" or group_id == "": + if not tg_api or not group_id: if debug: print("Telegram api key or chat(group) id not found.") print("You need to set TG_API and TG_GROUP_ID in the environment variable.")