summaryrefslogtreecommitdiff
path: root/poezio/windows
diff options
context:
space:
mode:
authormathieui <mathieui@mathieui.net>2017-10-13 23:15:03 +0200
committermathieui <mathieui@mathieui.net>2017-10-13 23:15:03 +0200
commitcee802b6efa027702d1e9fbaa6f440b22cc2996b (patch)
tree3073612e9c989b3445c4e431c8bd34278d8f99d5 /poezio/windows
parent858e3332791d74c25f0abd7659276ce15db6e1cf (diff)
downloadpoezio-cee802b6efa027702d1e9fbaa6f440b22cc2996b.tar.gz
poezio-cee802b6efa027702d1e9fbaa6f440b22cc2996b.tar.bz2
poezio-cee802b6efa027702d1e9fbaa6f440b22cc2996b.tar.xz
poezio-cee802b6efa027702d1e9fbaa6f440b22cc2996b.zip
Fix the last pylint error (do not set the roster contact filter to None)
Diffstat (limited to 'poezio/windows')
-rw-r--r--poezio/windows/roster_win.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/poezio/windows/roster_win.py b/poezio/windows/roster_win.py
index eda1cf10..73191e84 100644
--- a/poezio/windows/roster_win.py
+++ b/poezio/windows/roster_win.py
@@ -93,25 +93,25 @@ class RosterWin(Win):
return
log.debug('The roster has changed, rebuilding the cacheā€¦')
# This is a search
- if roster.contact_filter:
+ if roster.contact_filter is not roster.DEFAULT_FILTER:
self.roster_cache = []
sort = config.get('roster_sort', 'jid:show') or 'jid:show'
for contact in roster.get_contacts_sorted_filtered(sort):
self.roster_cache.append(contact)
else:
- show_offline = config.get('roster_show_offline') or roster.contact_filter
+ show_offline = config.get('roster_show_offline')
sort = config.get('roster_sort') or 'jid:show'
group_sort = config.get('roster_group_sort') or 'name'
self.roster_cache = []
# build the cache
for group in roster.get_groups(group_sort):
- contacts_filtered = group.get_contacts(roster.contact_filter)
+ contacts_filtered = group.get_contacts()
if (not show_offline and group.get_nb_connected_contacts() == 0) or not contacts_filtered:
continue # Ignore empty groups
self.roster_cache.append(group)
if group.folded:
continue # ignore folded groups
- for contact in group.get_contacts(roster.contact_filter, sort):
+ for contact in group.get_contacts(sort=sort):
if not show_offline and len(contact) == 0:
continue # ignore offline contacts
self.roster_cache.append(contact)