completed telegram subscriber list functionality

This commit is contained in:
sid 2018-06-30 21:32:22 +02:00 committed by GitHub
parent 86d63fe9a0
commit a8504971ea
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -13,6 +13,10 @@ class TelegramBot(Bot):
updates = tb.get_updates().wait()
reports = []
for update in updates:
if update.message.text =="/stop":
remove_telegram_subscribers(self, update.message.from.id)
else:
add_telegram_subscribers(self, update.message.from.id)
reports.append(Report(update.message.from.username,self,
update.message.text,None,update.message.date))
return reports