You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by ma...@apache.org on 2007/10/29 13:27:53 UTC
svn commit: r589599 -
/myfaces/tomahawk/trunk/core/src/main/java/org/apache/myfaces/custom/fileupload/HtmlFileUploadRenderer.java
Author: matzew
Date: Mon Oct 29 05:27:53 2007
New Revision: 589599
URL: http://svn.apache.org/viewvc?rev=589599&view=rev
Log:
TOMAHAWK-1137 - don't upload empty files, trigger as no file provided
don't submit empty files, handle
Modified:
myfaces/tomahawk/trunk/core/src/main/java/org/apache/myfaces/custom/fileupload/HtmlFileUploadRenderer.java
Modified: myfaces/tomahawk/trunk/core/src/main/java/org/apache/myfaces/custom/fileupload/HtmlFileUploadRenderer.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core/src/main/java/org/apache/myfaces/custom/fileupload/HtmlFileUploadRenderer.java?rev=589599&r1=589598&r2=589599&view=diff
==============================================================================
--- myfaces/tomahawk/trunk/core/src/main/java/org/apache/myfaces/custom/fileupload/HtmlFileUploadRenderer.java (original)
+++ myfaces/tomahawk/trunk/core/src/main/java/org/apache/myfaces/custom/fileupload/HtmlFileUploadRenderer.java Mon Oct 29 05:27:53 2007
@@ -178,7 +178,7 @@
{
UploadedFile file = (UploadedFile) submittedValue;
- if(file.getName()!=null && file.getName().length()>0)
+ if(file.getSize()>0 && file.getName()!=null && file.getName().length()>0)
{
return file;
}