mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-09 01:33:30 +02:00
Fix problem with sorting in collections
This commit is contained in:
parent
9dd662ac0b
commit
d9cd3fd0b0
1 changed files with 4 additions and 1 deletions
|
|
@ -237,7 +237,10 @@ def none_cmp(xx, yy):
|
|||
return 1
|
||||
if y is None:
|
||||
return -1
|
||||
c = cmp(sort_key(x), sort_key(y))
|
||||
if isinstance(x, unicode):
|
||||
c = cmp(sort_key(x), sort_key(y))
|
||||
else:
|
||||
c = cmp(x, y)
|
||||
if c != 0:
|
||||
return c
|
||||
# same as above -- no sort_key needed here
|
||||
|
|
|
|||
Loading…
Reference in a new issue