From a73f289bde0c1b21a24e70c89a13b160bb00d2ca Mon Sep 17 00:00:00 2001 From: xtaodada Date: Fri, 14 Aug 2020 22:49:18 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20sticker=20=E5=A2=9E=E5=8A=A0?= =?UTF-8?q?=E6=97=A0=E6=B3=95=E6=AD=A3=E7=A1=AE=E8=BF=9E=E6=8E=A5=E6=9C=8D?= =?UTF-8?q?=E5=8A=A1=E5=99=A8=E7=9A=84=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pagermaid/modules/sticker.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pagermaid/modules/sticker.py b/pagermaid/modules/sticker.py index 360bdd4..39f36b4 100644 --- a/pagermaid/modules/sticker.py +++ b/pagermaid/modules/sticker.py @@ -89,6 +89,9 @@ async def sticker(context): response = request.urlopen( request.Request(f'http://t.me/addstickers/{pack_name}')) + if not response.status == 200: + await context.edit("连接到 Telegram 服务器失败 . . .") + return http_response = response.read().decode("utf8").split('\n') if " A Telegram user has created the Sticker Set." not in \