mirror of
https://github.com/apache/struts.git
synced 2026-08-11 01:27:14 +00:00
WW-3914 solves problem with returning always system implementation of FileManager
git-svn-id: https://svn.apache.org/repos/asf/struts/struts2/trunk@1405930 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
+3
-5
@@ -56,11 +56,9 @@ public class DefaultFileManagerFactory implements FileManagerFactory {
|
||||
if (LOG.isDebugEnabled()) {
|
||||
LOG.debug("No user defined FileManager, looking up for internal implementations!");
|
||||
}
|
||||
if (fileManager == null) {
|
||||
for (FileManager fm : internals) {
|
||||
if (fm.support()) {
|
||||
return fm;
|
||||
}
|
||||
for (FileManager fm : internals) {
|
||||
if (fm.support()) {
|
||||
return fm;
|
||||
}
|
||||
}
|
||||
if (LOG.isDebugEnabled()) {
|
||||
|
||||
+1
@@ -35,6 +35,7 @@ public class DefaultFileManagerFactoryTest extends XWorkTestCase {
|
||||
// given
|
||||
fileManager = new DummyFileManager();
|
||||
DefaultFileManagerFactory factory = new DefaultFileManagerFactory();
|
||||
factory.setFileManager(new DefaultFileManager());
|
||||
factory.setContainer(new DummyContainer());
|
||||
|
||||
// when
|
||||
|
||||
Reference in New Issue
Block a user