Fix a traceback when sorting a listwin

This commit is contained in:
mathieui 2014-04-24 23:39:12 +02:00
parent 1bd9f78fe6
commit 98914b8b0a

View file

@ -2324,9 +2324,10 @@ class ListWin(Win):
if not col_name:
return
elif asc:
self.lines.sort(key=lambda x: x[col_name])
self.lines.sort(key=lambda x: x[self._columns[col_name]])
else:
self.lines.sort(key=lambda x: x[col_name], reverse=True)
self.lines.sort(key=lambda x: x[self._columns[col_name]],
reverse=True)
self.refresh()
curses.doupdate()