mirror of
https://github.com/chatmail/core.git
synced 2026-05-08 09:26:29 +03:00
api(deltachat-rpc-client): add Account.wait_for_incoming_msg()
This commit is contained in:
@@ -297,6 +297,12 @@ class Account:
|
||||
if event.kind == EventType.INCOMING_MSG:
|
||||
return event
|
||||
|
||||
def wait_for_incoming_msg(self):
|
||||
"""Wait for incoming message and return it.
|
||||
|
||||
Consumes all events before the next incoming message event."""
|
||||
return self.get_message_by_id(self.wait_for_incoming_msg_event().msg_id)
|
||||
|
||||
def wait_for_securejoin_inviter_success(self):
|
||||
while True:
|
||||
event = self.wait_for_event()
|
||||
|
||||
Reference in New Issue
Block a user