Don't act like if self contact is in group General. See #4000.
Don't make General group visible when we have self contact.
This commit is contained in:
parent
40e360d1c8
commit
0d645437d8
|
@ -953,7 +953,9 @@ class RosterWindow:
|
||||||
groups = contact.groups
|
groups = contact.groups
|
||||||
if contact.is_observer():
|
if contact.is_observer():
|
||||||
groups = [_('Observers')]
|
groups = [_('Observers')]
|
||||||
elif not groups:
|
elif not groups and \
|
||||||
|
not contact.jid == gajim.get_jid_from_account(account):
|
||||||
|
# no group, and not self contact
|
||||||
groups = [_('General')]
|
groups = [_('General')]
|
||||||
|
|
||||||
# gets number of unread gc marked messages
|
# gets number of unread gc marked messages
|
||||||
|
@ -1375,9 +1377,11 @@ class RosterWindow:
|
||||||
accounts = [account]
|
accounts = [account]
|
||||||
for _acc in accounts:
|
for _acc in accounts:
|
||||||
for contact in gajim.contacts.iter_contacts(_acc):
|
for contact in gajim.contacts.iter_contacts(_acc):
|
||||||
# Is this contact in this group ?
|
# Is this contact in this group ? (last part of if check if it's
|
||||||
|
# self contact)
|
||||||
if group in contact.groups or (group == _('General') and not \
|
if group in contact.groups or (group == _('General') and not \
|
||||||
contact.groups):
|
contact.groups and \
|
||||||
|
not contact.jid == gajim.get_jid_from_account(account)):
|
||||||
if self.contact_is_visible(contact, _acc):
|
if self.contact_is_visible(contact, _acc):
|
||||||
return True
|
return True
|
||||||
return False
|
return False
|
||||||
|
|
Loading…
Reference in New Issue