Commits

Kai Diefenbach committed 8ce8d71 Merge

Updated versions

Comments (0)

Files changed (3)

 # built documents.
 #
 # The short X.Y version.
-version = '1.0a1'
+version = '1.0'
 # The full version, including alpha/beta/rc tags.
-release = '1.0a1'
+release = '1.0'
 
 # The language for content autogenerated by Sphinx. Refer to documentation
 # for a list of supported languages.

permissions/utils.py

 
     if user.is_anonymous():
         user = None
-    else:    
-        groups.extend(list(Group.objects.filter(user=user)))
+    else:
+        groups.extend(Group.objects.filter(user=user))
 
     ct = ContentType.objects.get_for_model(obj)
 
     while obj is not None:
-        if user is not None:
+        if user:
             p = ObjectPermission.objects.filter(
                 content_type=ct, content_id=obj.id, user=user, permission__codename = codename)
-        
+
             if p.count() > 0:
                 return True
 
         p = ObjectPermission.objects.filter(
             content_type=ct, content_id=obj.id, group__in=groups, permission__codename = codename)
 
-        # if p.exists():
-        #     return True
-
         if p.count() > 0:
             return True
 
 from setuptools import setup, find_packages
 import os
 
-version = '1.0a1'
+version = '1.0a2'
 
 here = os.path.abspath(os.path.dirname(__file__))
 README = open(os.path.join(here, 'README.txt')).read()