[Zope-CVS] CVS: Products/BTreeFolder2 - BTreeFolder2.py:1.27

Zachery Bir zbir at urbanape.com
Wed Mar 17 17:49:25 EST 2004


Update of /cvs-repository/Products/BTreeFolder2
In directory cvs.zope.org:/tmp/cvs-serv12128

Modified Files:
	BTreeFolder2.py 
Log Message:
The key for 'Owner' local role should be the user's Id, not UserName

Special Users and security managers that return None objects should not play.


=== Products/BTreeFolder2/BTreeFolder2.py 1.26 => 1.27 ===
--- Products/BTreeFolder2/BTreeFolder2.py:1.26	Wed Mar 17 17:48:14 2004
+++ Products/BTreeFolder2/BTreeFolder2.py	Wed Mar 17 17:49:25 2004
@@ -424,9 +424,9 @@
                 if object.__ac_local_roles__ is None:
                     user=getSecurityManager().getUser()
                     if user is not None:
-                        name=user.getId()
-                        if name != 'Anonymous User':
-                            object.manage_setLocalRoles(name, ['Owner'])
+                        userid=user.getId()
+                        if userid is not None:
+                            object.manage_setLocalRoles(userid, ['Owner'])
 
         object.manage_afterAdd(object, self)
         return id




More information about the Zope-CVS mailing list