mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2024-11-10 19:46:36 +03:00
parent
fd09284598
commit
af18538722
|
@ -333,9 +333,12 @@ class AuthMethods:
|
||||||
|
|
||||||
# May raise PhoneCodeEmptyError, PhoneCodeExpiredError,
|
# May raise PhoneCodeEmptyError, PhoneCodeExpiredError,
|
||||||
# PhoneCodeHashEmptyError or PhoneCodeInvalidError.
|
# PhoneCodeHashEmptyError or PhoneCodeInvalidError.
|
||||||
request = functions.auth.SignInRequest(
|
try:
|
||||||
phone, phone_code_hash, str(code)
|
request = functions.auth.SignInRequest(
|
||||||
)
|
phone, phone_code_hash, str(code)
|
||||||
|
)
|
||||||
|
except errors.PhoneCodeExpiredError:
|
||||||
|
self._phone_code_hash.pop(phone, None)
|
||||||
elif password:
|
elif password:
|
||||||
pwd = await self(functions.account.GetPasswordRequest())
|
pwd = await self(functions.account.GetPasswordRequest())
|
||||||
request = functions.auth.CheckPasswordRequest(
|
request = functions.auth.CheckPasswordRequest(
|
||||||
|
|
Loading…
Reference in New Issue
Block a user