changeset b71c601a79bd in /home/hg/repos/gajim
details:http://hg.gajim.org/gajim?cmd=changeset;node=b71c601a79bd description: ignore groupchat invitations from contacts that are not in roster if ignore_unknown_contacts is enabled. Fixes #6057
diffstat:
src/common/connection_handlers_events.py | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-)
diffs (15 lines):
diff -r 79a998b4324a -r b71c601a79bd src/common/connection_handlers_events.py --- a/src/common/connection_handlers_events.py Tue Nov 30 11:41:14 2010 +0100 +++ b/src/common/connection_handlers_events.py Tue Nov 30 23:36:57 2010 +0100 @@ -1007,6 +1007,11 @@ except helpers.InvalidFormat: log.warn('Invalid JID: %s, ignoring it' % item.getAttr('from')) return + jid = gajim.get_jid_without_resource(self.jid_from) + if gajim.config.get_per('accounts', self.conn.name, + 'ignore_unknown_contacts') and not gajim.contacts.get_contacts( + self.conn.name, jid): + return self.reason = item.getTagData('reason') self.password = self.msg_obj.invite_tag.getTagData('password')