Author: shane.bryzak(a)jboss.com
Date: 2010-01-06 22:58:59 -0500 (Wed, 06 Jan 2010)
New Revision: 11920
Modified:
modules/remoting/trunk/src/main/java/org/jboss/seam/remoting/model/ModelHandler.java
Log:
fix NPE
Modified:
modules/remoting/trunk/src/main/java/org/jboss/seam/remoting/model/ModelHandler.java
===================================================================
---
modules/remoting/trunk/src/main/java/org/jboss/seam/remoting/model/ModelHandler.java 2010-01-07
03:28:27 UTC (rev 11919)
+++
modules/remoting/trunk/src/main/java/org/jboss/seam/remoting/model/ModelHandler.java 2010-01-07
03:58:59 UTC (rev 11920)
@@ -220,6 +220,13 @@
Model model = registry.getModel(modelElement.attributeValue("id"));
model.setAction(null);
+ // We clone the outRefs to the inRefs so that the context can locate
+ // already-loaded refs when unmarshalling
+ for (int i = 0; i < model.getCallContext().getOutRefs().size(); i++)
+ {
+ model.getCallContext().getInRefs().put("" + i,
model.getCallContext().getOutRefs().get(i));
+ }
+
CallContext ctx = new CallContext(beanManager);
Element refsElement = modelElement.element("refs");
@@ -262,7 +269,7 @@
else
{
Type t = ((BeanWrapper) target).getBeanPropertyType(name);
- if (!cloneBagContents(source.convert(t), targetBag))
+ if (!cloneBagContents(source.convert(t), ((Wrapper)
targetBag).getValue()));
{
((BeanWrapper) target).setBeanProperty(name, source);
}
Show replies by date