diff options
author | Lars-Dominik Braun <lars@6xq.net> | 2015-05-27 16:40:49 +0200 |
---|---|---|
committer | Lars-Dominik Braun <lars@6xq.net> | 2015-05-27 16:40:49 +0200 |
commit | fd7e03c31d01b71b4e0647c50066ce304524aaad (patch) | |
tree | 6a94a45dc45a20755f93c99d7b290e269c35bc82 /data | |
parent | d9b2ed24a50c149bab7883b79b298e0276302f15 (diff) | |
download | comatose-fd7e03c31d01b71b4e0647c50066ce304524aaad.tar.gz comatose-fd7e03c31d01b71b4e0647c50066ce304524aaad.tar.bz2 comatose-fd7e03c31d01b71b4e0647c50066ce304524aaad.zip |
Fix sorting by year
Diffstat (limited to 'data')
-rw-r--r-- | data/script.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/data/script.js b/data/script.js index f76a862..84cb562 100644 --- a/data/script.js +++ b/data/script.js @@ -15,7 +15,7 @@ $(document).ready (function () { items.detach ().sort (function (nodeA, nodeB) { var a = $(nodeA).data (by); var b = $(nodeB).data (by); - if (by == 'rank') { + if (by == 'rank' || by == 'year') { a = parseFloat (a); b = parseFloat (b); return a > b ? 1 : (a < b ? -1 : 0); |