@property
def is_group(self):
    'True if the message was sent on a group or megagroup.'
    if ((self._broadcast is None) and self.chat):
        self._broadcast = getattr(self.chat, 'broadcast', None)
    return (isinstance(self._chat_peer, (types.PeerChat, types.PeerChannel)) and (not self._broadcast))
True if the message was sent on a group or megagroup.
@property
def is_group(self):
    
    if ((self._broadcast is None) and self.chat):
        self._broadcast = getattr(self.chat, 'broadcast', None)
    return (isinstance(self._chat_peer, (types.PeerChat, types.PeerChannel)) and (not self._broadcast))