no exception on invalid sort
This commit is contained in:
parent
79b9eda351
commit
a7b12cc159
@ -144,7 +144,11 @@ class index:
|
|||||||
|
|
||||||
#sorting:
|
#sorting:
|
||||||
if vars.sort:
|
if vars.sort:
|
||||||
torrent_list.sort(key=attrgetter(vars.sort))
|
try:
|
||||||
|
torrent_list.sort(key=attrgetter(vars.sort))
|
||||||
|
except:
|
||||||
|
log.debug('Sorting Failed')
|
||||||
|
|
||||||
if vars.order == 'up':
|
if vars.order == 'up':
|
||||||
torrent_list = reversed(torrent_list)
|
torrent_list = reversed(torrent_list)
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user