mirror of
https://github.com/apache/struts.git
synced 2026-08-06 23:27:07 +00:00
WW-2240 Temporary workaround for NPE problems when doing info logging. Patch by Benjamin McCann
git-svn-id: https://svn.apache.org/repos/asf/struts/struts2/trunk@615436 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -274,8 +274,9 @@ public class FileUploadInterceptor extends AbstractInterceptor {
|
||||
File[] file = multiWrapper.getFiles(inputValue);
|
||||
for (int index = 0; index < file.length; index++) {
|
||||
File currentFile = file[index];
|
||||
LOG.info(getTextMessage("struts.messages.removing.file", new Object[]{inputValue, currentFile}, ActionContext.getContext().getLocale()));
|
||||
|
||||
if(LOG.isInfoEnabled()) {
|
||||
LOG.info(getTextMessage("struts.messages.removing.file", new Object[]{inputValue, currentFile}, ActionContext.getContext().getLocale()));
|
||||
}
|
||||
if ((currentFile != null) && currentFile.isFile()) {
|
||||
currentFile.delete();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user