shuber 2005/12/19 15:27:53 CET
Modified files:
core/src/java/org/jahia/services/fields
ContentApplicationField.java
Log:
Fixed ClassCastException due to trying to cast to ParamBean when using
ProcessingContext during indexation of application field.
Revision Changes Path
1.10 +10 -3
jahia/core/src/java/org/jahia/services/fields/ContentApplicationField.java
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jahia/core/src/java/org/jahia/services/fields/ContentApplicationField.java.diff?r1=1.9&r2=1.10&f=h
Index: ContentApplicationField.java
===================================================================
RCS file:
/home/cvs/repository/jahia/core/src/java/org/jahia/services/fields/ContentApplicationField.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- ContentApplicationField.java 12 Oct 2005 16:04:47 -0000 1.9
+++ ContentApplicationField.java 19 Dec 2005 14:27:53 -0000 1.10
@@ -98,9 +98,16 @@
String tmpValue = "";
if (jParams != null) {
- tmpValue = ServicesRegistry.getInstance ().
- getApplicationsDispatchService ().
- getAppOutput (this.getID (), appID, (ParamBean) jParams);
+ if (jParams instanceof ParamBean) {
+ tmpValue = ServicesRegistry.getInstance ().
+ getApplicationsDispatchService ().
+ getAppOutput (this.getID (), appID, (ParamBean)
jParams);
+ } else {
+ // we are not in the context of an HTTP request, so we
cannot dispatch
+ // to the web application. This happens for example in the
case of
+ // the background indexation of the search engine.
+ tmpValue="";
+ }
}
if (tmpValue != null) {
try {