diff options
author | Nicolás Reynolds <fauno@kiwwwi.com.ar> | 2010-12-31 15:42:55 -0300 |
---|---|---|
committer | Nicolás Reynolds <fauno@kiwwwi.com.ar> | 2010-12-31 15:42:55 -0300 |
commit | c9178286885d60741eb0e696c3e345e3b0dfb9e2 (patch) | |
tree | 7738211d84337e897acfd2263be0b33352becae0 /public | |
parent | ebcd492d39cd0525b768a48558e50041aa0961e3 (diff) | |
parent | 84897adcdc698678f2ee8d2292cfe4271c6335e4 (diff) |
Merge git://projects.archlinux.org/archweb
Conflicts:
templates/public/index.html
urls.py
Diffstat (limited to 'public')
-rw-r--r-- | public/utils.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/public/utils.py b/public/utils.py index 2801c939..81f589f7 100644 --- a/public/utils.py +++ b/public/utils.py @@ -13,7 +13,7 @@ def get_recent_updates(): # grab a few extra so we can hopefully catch everything we need pkgs += list(Package.objects.select_related( 'arch', 'repo').filter(arch=arch).order_by('-last_update')[:50]) - pkgs.sort(key=lambda q: q.last_update) + pkgs.sort(key=attrgetter('last_update')) updates = [] ctr = 0 while ctr < 15 and len(pkgs) > 0: @@ -22,7 +22,7 @@ def get_recent_updates(): is_same = lambda q: p.is_same_version(q) and p.repo == q.repo samepkgs = filter(is_same, pkgs) samepkgs.append(p) - samepkgs.sort(key=attrgetter('arch.name')) + samepkgs.sort(key=attrgetter('arch')) updates.append(samepkgs) for q in samepkgs: if p != q: pkgs.remove(q) |