Remove broken force_sms

This commit is contained in:
Lonami Exo
2022-01-16 12:19:07 +01:00
parent a95393648f
commit a3513d5232
3 changed files with 19 additions and 38 deletions

View File

@@ -321,7 +321,6 @@ class TelegramClient:
password: typing.Callable[[], str] = lambda: getpass.getpass('Please enter your password: '),
*,
bot_token: str = None,
force_sms: bool = False,
code_callback: typing.Callable[[], typing.Union[str, int]] = None,
first_name: str = 'New User',
last_name: str = '',
@@ -358,10 +357,6 @@ class TelegramClient:
to log in as a bot. Cannot be specified with ``phone`` (only
one of either allowed).
force_sms (`bool`, optional):
Whether to force sending the code request as SMS.
This only makes sense when signing in with a `phone`.
code_callback (`callable`, optional):
A callable that will be used to retrieve the Telegram
login code. Defaults to `input()`.
@@ -513,9 +508,7 @@ class TelegramClient:
@forward_call(auth.send_code_request)
async def send_code_request(
self: 'TelegramClient',
phone: str,
*,
force_sms: bool = False) -> '_tl.auth.SentCode':
phone: str) -> '_tl.auth.SentCode':
"""
Sends the Telegram code needed to login to the given phone number.
@@ -523,9 +516,6 @@ class TelegramClient:
phone (`str` | `int`):
The phone to which the code will be sent.
force_sms (`bool`, optional):
Whether to force sending as SMS.
Returns
An instance of :tl:`SentCode`.