mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2024-11-25 19:03:46 +03:00
Fix calls to remove_event_handler
This commit is contained in:
parent
d1dba60278
commit
48bd061562
|
@ -2877,6 +2877,7 @@ class TelegramClient:
|
|||
self: 'TelegramClient',
|
||||
callback: updates.Callback = None,
|
||||
event: EventBuilder = None,
|
||||
*,
|
||||
priority=None,
|
||||
) -> int:
|
||||
"""
|
||||
|
|
|
@ -97,9 +97,10 @@ def add_event_handler(
|
|||
|
||||
def remove_event_handler(
|
||||
self: 'TelegramClient',
|
||||
callback,
|
||||
event,
|
||||
priority,
|
||||
callback=None,
|
||||
event=None,
|
||||
*,
|
||||
priority=None,
|
||||
):
|
||||
if callback is None and event is None and priority is None:
|
||||
raise ValueError('must specify at least one of callback, event or priority')
|
||||
|
|
Loading…
Reference in New Issue
Block a user