count -> exists

This commit is contained in:
Akita Noek
2016-03-31 09:39:50 -04:00
parent 6b5c4338cc
commit 156aeb931f
+1 -1
View File
@@ -644,7 +644,7 @@ class ProjectAccess(BaseAccess):
if self.user.is_superuser:
return True
qs = Organization.accessible_objects(self.user, ALL_PERMISSIONS)
return bool(qs.count() > 0)
return qs.exists()
def can_change(self, obj, data):
if self.user.is_superuser: