mirror of
https://github.com/chatmail/core.git
synced 2026-05-03 21:36:29 +03:00
Add JSON-RPC API can_send()
This commit is contained in:
@@ -105,6 +105,10 @@ class Chat:
|
||||
info = await self._rpc.get_full_chat_by_id(self.account.id, self.id)
|
||||
return AttrDict(chat=self, **info)
|
||||
|
||||
async def can_send(self) -> bool:
|
||||
"""Return true if messages can be sent to the chat."""
|
||||
return await self._rpc.can_send(self.account.id, self.id)
|
||||
|
||||
async def send_message(
|
||||
self,
|
||||
text: Optional[str] = None,
|
||||
|
||||
Reference in New Issue
Block a user