mirror of
https://github.com/chatmail/core.git
synced 2026-04-06 15:42:10 +03:00
represent archivestate as enum
before it was a boolean, even though it is a 3 state
This commit is contained in:
@@ -423,7 +423,13 @@ class Chat(object):
|
||||
"""return True if this chat is archived.
|
||||
:returns: True if archived.
|
||||
"""
|
||||
return lib.dc_chat_get_archived(self._dc_chat)
|
||||
return lib.dc_chat_get_archived(self._dc_chat) == 1
|
||||
|
||||
def is_pinned(self):
|
||||
"""return True if this chat is pinned.
|
||||
:returns: True if pinned.
|
||||
"""
|
||||
return lib.dc_chat_get_archived(self._dc_chat) == 2
|
||||
|
||||
def enable_sending_locations(self, seconds):
|
||||
"""enable sending locations for this chat.
|
||||
|
||||
Reference in New Issue
Block a user