]> arthur.barton.de Git - bup.git/blobdiff - lib/bup/git.py
Add compat.items() and use it
[bup.git] / lib / bup / git.py
index 798bea2cb7328c9ca9356379843e2f5029194952..8150f7c0c593ef3a1795b0866ee16b8a1b3282f7 100644 (file)
@@ -552,7 +552,7 @@ class PackIdxList:
             if self.bloom is None and os.path.exists(bfull):
                 self.bloom = bloom.ShaBloom(bfull)
             self.packs = list(set(d.values()))
-            self.packs.sort(lambda x,y: -cmp(len(x),len(y)))
+            self.packs.sort(reverse=True, key=lambda x: len(x))
             if self.bloom and self.bloom.valid() and len(self.bloom) >= len(self):
                 self.do_bloom = True
             else: