mirror of
https://github.com/ansible/awx.git
synced 2026-05-20 15:27:47 -02:30
make special case for no results slightly more clear
This commit is contained in:
@@ -673,7 +673,7 @@ class OrganizationDetail(RetrieveUpdateDestroyAPIView):
|
|||||||
admins=Count('admin_role__members', distinct=True)
|
admins=Count('admin_role__members', distinct=True)
|
||||||
).values('users', 'admins')
|
).values('users', 'admins')
|
||||||
|
|
||||||
if direct_counts.count() == 0:
|
if not direct_counts:
|
||||||
return full_context
|
return full_context
|
||||||
|
|
||||||
org_counts = direct_counts[0]
|
org_counts = direct_counts[0]
|
||||||
|
|||||||
Reference in New Issue
Block a user