2
0
mirror of https://github.com/pyrogram/pyrogram synced 2025-08-28 12:57:52 +00:00

Allow returning sms codes as int from the callback function

This commit is contained in:
Dan 2018-04-08 12:46:02 +02:00
parent dfc8d00adb
commit 26a41ec00e

View File

@ -370,7 +370,7 @@ class Client:
self.phone_code = (
input("Enter phone code: ") if self.phone_code is None
else self.phone_code if type(self.phone_code) is str
else self.phone_code()
else str(self.phone_code())
)
try: