Author: ningjiang Date: Fri May 18 15:51:19 2012 New Revision: 1340142 URL: http://svn.apache.org/viewvc?rev=1340142&view=rev Log: Merged revisions 1339963 via svnmerge from https://svn.apache.org/repos/asf/camel/branches/camel-2.9.x
................ r1339963 | ningjiang | 2012-05-18 11:25:06 +0800 (Fri, 18 May 2012) | 9 lines Merged revisions 1339962 via svnmerge from https://svn.apache.org/repos/asf/camel/trunk ........ r1339962 | ningjiang | 2012-05-18 11:13:35 +0800 (Fri, 18 May 2012) | 1 line CAMEL-5276 Fix the issue that the ObjectHelper will return false for a node without children ........ ................ Modified: camel/branches/camel-2.8.x/ (props changed) camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java Propchange: camel/branches/camel-2.8.x/ ------------------------------------------------------------------------------ Merged /camel/trunk:r1339962 Merged /camel/branches/camel-2.9.x:r1339963 Propchange: camel/branches/camel-2.8.x/ ------------------------------------------------------------------------------ Binary property 'svnmerge-integrated' - no diff available. Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java?rev=1340142&r1=1340141&r2=1340142&view=diff ============================================================================== --- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java (original) +++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java Fri May 18 15:51:19 2012 @@ -1145,7 +1145,10 @@ public final class ObjectHelper { return false; } } else if (value instanceof NodeList) { - // is it an empty dom + // is it an empty dom with empty attributes + if (value instanceof Node && ((Node)value).hasAttributes()) { + return true; + } NodeList list = (NodeList) value; return list.getLength() > 0; } else if (value instanceof Collection) {
