Fixed printing lists for users
This commit is contained in:
parent
8fac5ad7c2
commit
9af8d9a496
3 changed files with 6 additions and 9 deletions
10
hrafn.py
10
hrafn.py
|
@ -341,23 +341,19 @@ class Hrafn():
|
|||
found_lists = []
|
||||
username = re.sub('user: ', '', name)
|
||||
|
||||
|
||||
# We're not going to change the data, just access it.
|
||||
# This condition only exists to let us know when the lists are
|
||||
# ready
|
||||
# Ergo, we can release it right after we get out of the conditional
|
||||
self.lists_cond.acquire()
|
||||
while not self.lists.has_key(self.username):
|
||||
self.lists_cond.wait()
|
||||
self.lists_cond.release()
|
||||
|
||||
for list_name in self.lists[self.username].keys():
|
||||
try:
|
||||
i = self.lists[self.username][list_name].index(username)
|
||||
found_lists.append(list_name)
|
||||
except:
|
||||
except ValueError:
|
||||
pass
|
||||
new_pane.set_lists(found_lists)
|
||||
|
||||
self.lists_cond.release()
|
||||
|
||||
new_pane.connect('at-clicked', self.on_at_button_clicked)
|
||||
new_pane.connect('follow-clicked', self.on_follow_button_clicked)
|
||||
|
|
Reference in a new issue