[CMF-checkins] CVS: Products/CMFDefault - RegistrationTool.py:1.30

Lennart Regebro regebro at nuxeo.com
Fri Sep 3 07:11:56 EDT 2004


Update of /cvs-repository/Products/CMFDefault
In directory cvs.zope.org:/tmp/cvs-serv21911

Modified Files:
	RegistrationTool.py 
Log Message:
RegistrationTool: An optional password can now be passed to registeredNotify() (Issue #277).


=== Products/CMFDefault/RegistrationTool.py 1.29 => 1.30 ===
--- Products/CMFDefault/RegistrationTool.py:1.29	Thu Aug 12 11:07:40 2004
+++ Products/CMFDefault/RegistrationTool.py	Fri Sep  3 07:11:55 2004
@@ -169,7 +169,7 @@
         return self.mail_password_response( self, REQUEST )
 
     security.declarePublic( 'registeredNotify' )
-    def registeredNotify( self, new_member_id ):
+    def registeredNotify( self, new_member_id, password=None ):
         """ Handle mailing the registration / welcome message.
         """
         membership = getToolByName( self, 'portal_membership' )
@@ -178,7 +178,8 @@
         if member is None:
             raise ValueError('The username you entered could not be found.')
 
-        password = member.getPassword()
+        if password is None:
+            password = member.getPassword()
 
         email = member.getProperty( 'email' )
 



More information about the CMF-checkins mailing list