Skip to content
Browse files

XWIKI-7568 : Implement mechanism to hide technical content

Minor fixes.
  • Loading branch information...
1 parent ded8102 commit 410c3bc03298668714e17fd8b8beacc40529870c @jvdrean jvdrean committed Apr 10, 2012
View
1 xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/XWiki.java
@@ -112,7 +112,6 @@
import org.xwiki.bridge.event.ApplicationReadyEvent;
import org.xwiki.observation.event.Event;
import org.xwiki.query.QueryException;
-import org.xwiki.query.QueryFilter;
import org.xwiki.rendering.macro.wikibridge.WikiMacroInitializer;
import org.xwiki.rendering.parser.ParseException;
import org.xwiki.rendering.syntax.Syntax;
View
10 ...uery/xwiki-platform-query-manager/src/main/java/org/xwiki/query/internal/ScriptQuery.java
@@ -20,6 +20,8 @@
package org.xwiki.query.internal;
import org.apache.commons.lang3.StringUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
import org.xwiki.component.manager.ComponentLookupException;
import org.xwiki.component.manager.ComponentManager;
import org.xwiki.query.Query;
@@ -33,11 +35,16 @@
* Query wrapper that allows to set filter from the filter component hint.
*
* @version $Id$
- * @since 4.1M1
+ * @since 4.0RC1
*/
public class ScriptQuery implements Query
{
/**
+ * Used to log possible warnings.
+ */
+ private static final Logger LOGGER = LoggerFactory.getLogger(ScriptQuery.class);
+
+ /**
* Used to retrieve {@link org.xwiki.query.QueryFilter} implementations.
*/
private ComponentManager componentManager;
@@ -72,6 +79,7 @@ public Query setFilter(String filter)
setFilter(componentManager.lookup(QueryFilter.class, filter));
} catch (ComponentLookupException e) {
// We need to avoid throwing exceptions in the wiki if the filter does not exist.
+ LOGGER.warn(String.format("Failed to load QueryFilter with component hint [%s]", filter));
}
} else {
query.setFilter(null);

0 comments on commit 410c3bc

Please sign in to comment.
Something went wrong with that request. Please try again.