Ver código fonte

#2707 improve hasComponent

Shinsuke Sugaya 2 anos atrás
pai
commit
c71bffa902

+ 4 - 1
src/main/java/org/codelibs/fess/util/ComponentUtil.java

@@ -541,7 +541,10 @@ public final class ComponentUtil {
     }
 
     public static boolean hasComponent(final String componentKey) {
-        return SingletonLaContainerFactory.getContainer().hasComponentDef(componentKey);
+        if (SingletonLaContainerFactory.getContainer().hasComponentDef(componentKey)) {
+            return true;
+        }
+        return componentMap.containsKey(componentKey);
     }
 
     public static boolean hasQueryParser() {