diff options
author | Daniel Hahler <git@thequod.de> | 2017-06-29 01:35:46 +0200 |
---|---|---|
committer | Daniel Hahler <git@thequod.de> | 2017-06-29 01:35:46 +0200 |
commit | 17d282301107081a2907cfb2a4188a06a71a2446 (patch) | |
tree | b6c2b44dddf893c6b306159d6bfda114bc2080c7 | |
parent | 87f13a40b759397574c3d3168fc9db9c34060018 (diff) | |
download | archweb-17d282301107081a2907cfb2a4188a06a71a2446.tar.gz archweb-17d282301107081a2907cfb2a4188a06a71a2446.zip |
Fix RemovedInDjango19Warning
> Passing callable arguments to queryset is deprecated.
-rw-r--r-- | public/views.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/public/views.py b/public/views.py index 6861cf62..ad053b43 100644 --- a/public/views.py +++ b/public/views.py @@ -98,7 +98,7 @@ def keys(request): user_key_ids = frozenset(user.userprofile.pgp_key[-16:] for user in users if user.userprofile.pgp_key) - not_expired = Q(expires__gt=datetime.utcnow) | Q(expires__isnull=True) + not_expired = Q(expires__gt=datetime.utcnow()) | Q(expires__isnull=True) master_keys = MasterKey.objects.select_related('owner', 'revoker', 'owner__userprofile', 'revoker__userprofile').filter( revoked__isnull=True) @@ -162,7 +162,7 @@ def keys_json(request): 'group': 'cacert', }) - not_expired = Q(expires__gt=datetime.utcnow) | Q(expires__isnull=True) + not_expired = Q(expires__gt=datetime.utcnow()) | Q(expires__isnull=True) signatures = PGPSignature.objects.filter(not_expired, revoked__isnull=True) edge_list = [{ 'signee': sig.signee, 'signer': sig.signer } for sig in signatures] |