fix import script

This commit is contained in:
bakatrouble 2019-03-04 02:33:57 +03:00
parent c5d7d1b3ed
commit 3b922b6cb8

View File

@ -11,6 +11,11 @@ if __name__ == '__main__':
conn = get_conn()
uids = input('Please input user ids split by spaces: ')
for uid in uids.split():
try:
uid = int(uid)
except (ValueError, TypeError):
pass
conn.root.subscribers[uid] = Subscriber.from_chat(bot.get_chat(uid))
commit()
conn.close()