You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by cr...@locus.apache.org on 2000/09/24 05:59:49 UTC

cvs commit: jakarta-struts/src/example/org/apache/struts/example RegistrationForm.java

craigmcc    00/09/23 20:59:49

  Modified:    src/example/org/apache/struts/example RegistrationForm.java
  Log:
  Correctly compare the two passwords, instead of comparing the first password
  to itself.
  
  Submitted by:  Joe Peer <jo...@wap-force.net>
  
  Revision  Changes    Path
  1.6       +5 -5      jakarta-struts/src/example/org/apache/struts/example/RegistrationForm.java
  
  Index: RegistrationForm.java
  ===================================================================
  RCS file: /home/cvs/jakarta-struts/src/example/org/apache/struts/example/RegistrationForm.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- RegistrationForm.java	2000/08/01 20:03:24	1.5
  +++ RegistrationForm.java	2000/09/24 03:59:49	1.6
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-struts/src/example/org/apache/struts/example/RegistrationForm.java,v 1.5 2000/08/01 20:03:24 craigmcc Exp $
  - * $Revision: 1.5 $
  - * $Date: 2000/08/01 20:03:24 $
  + * $Header: /home/cvs/jakarta-struts/src/example/org/apache/struts/example/RegistrationForm.java,v 1.6 2000/09/24 03:59:49 craigmcc Exp $
  + * $Revision: 1.6 $
  + * $Date: 2000/09/24 03:59:49 $
    *
    * ====================================================================
    *
  @@ -88,7 +88,7 @@
    * </ul>
    *
    * @author Craig R. McClanahan
  - * @version $Revision: 1.5 $ $Date: 2000/08/01 20:03:24 $
  + * @version $Revision: 1.6 $ $Date: 2000/09/24 03:59:49 $
    */
   
   public final class RegistrationForm implements ValidatingActionForm  {
  @@ -330,7 +330,7 @@
   	ErrorMessages errors = new ErrorMessages();
   	if ((username == null) || (username.length() < 1))
   	    errors.addError("error.username.required");
  -	if (!password.equals(password))
  +	if (!password.equals(password2))
   	    errors.addError("error.password.match");
   	if ((fromAddress == null) || (fromAddress.length() < 1))
   	    errors.addError("error.fromAddress.required");