diff options
author | Dan McGee <dan@archlinux.org> | 2012-11-16 23:20:11 +0100 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2012-11-16 23:37:52 +0100 |
commit | 6dd4d54bb0adbbb0f8c2b1beaa92b7a58971cf88 (patch) | |
tree | ce20ff9bf1118c8d383eed352bcdcbf064cb5269 /public | |
parent | b3979dd2315ce1aef779abdb646562d7bba7a44f (diff) | |
download | archweb-6dd4d54bb0adbbb0f8c2b1beaa92b7a58971cf88.tar.gz archweb-6dd4d54bb0adbbb0f8c2b1beaa92b7a58971cf88.tar.xz |
Use Python 2.7 dictionary comprehension syntax
Rather than the old idiom of dict((k, v) for <> in <>).
Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'public')
-rw-r--r-- | public/views.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/public/views.py b/public/views.py index 9612076..3e15f9d 100644 --- a/public/views.py +++ b/public/views.py @@ -118,7 +118,7 @@ def keys(request): sig_counts = PGPSignature.objects.filter(not_expired, valid=True, signee__in=user_key_ids).values_list('signer').annotate( Count('signer')) - sig_counts = dict((key_id[-16:], ct) for key_id, ct in sig_counts) + sig_counts = {key_id[-16:]: ct for key_id, ct in sig_counts} for key in master_keys: key.signature_count = sig_counts.get(key.pgp_key[-16:], 0) |