cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sylv...@apache.org
Subject svn commit: rev 53782 - cocoon/branches/BRANCH_2_1_X/src/blocks/forms/java/org/apache/cocoon/forms/formmodel
Date Tue, 05 Oct 2004 07:54:05 GMT
Author: sylvain
Date: Tue Oct  5 00:54:03 2004
New Revision: 53782

Modified:
   cocoon/branches/BRANCH_2_1_X/src/blocks/forms/java/org/apache/cocoon/forms/formmodel/Upload.java
Log:
ooops. avoid sending an exception at each call :-/

Modified: cocoon/branches/BRANCH_2_1_X/src/blocks/forms/java/org/apache/cocoon/forms/formmodel/Upload.java
==============================================================================
--- cocoon/branches/BRANCH_2_1_X/src/blocks/forms/java/org/apache/cocoon/forms/formmodel/Upload.java
(original)
+++ cocoon/branches/BRANCH_2_1_X/src/blocks/forms/java/org/apache/cocoon/forms/formmodel/Upload.java
Tue Oct  5 00:54:03 2004
@@ -61,8 +61,9 @@
     public void setValue(Object object) {
         if ((object == null) || (object instanceof Part)) {
             this.part = (Part)object;
+        } else {
+            throw new RuntimeException("The value of an upload widget must be of type " +
Part.class + ".");
         }
-        throw new RuntimeException("The value of an upload widget must be of type " + Part.class
+ ".");
     }
 
     public void readFromRequest(FormContext formContext) {

Mime
View raw message