Add other message types exclusions to Message.is_system

Message.is_system was checking if self.type is MessageType.default
but now there are other MessageTypes that are not system messages
This commit is contained in:
SYCKGit 2021-08-18 10:12:48 +05:30 committed by GitHub
parent c4ee9dcafa
commit f7a3ea90b8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -979,7 +979,7 @@ class Message(Hashable):
.. versionadded:: 1.3
"""
return self.type is not MessageType.default
return self.type not in (MessageType.default, MessageType.reply, MessageType.application_command, MessageType.thread_starter_message)
@utils.cached_slot_property('_cs_system_content')
def system_content(self):