[319923] NPE in DefaultXMLPartitionFormatter
diff --git a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/formatter/DefaultXMLPartitionFormatter.java b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/formatter/DefaultXMLPartitionFormatter.java
index 61c3cff..447aabc 100644
--- a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/formatter/DefaultXMLPartitionFormatter.java
+++ b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/formatter/DefaultXMLPartitionFormatter.java
@@ -549,7 +549,7 @@
 					DOMRegion childDOMRegion = new DOMRegion();
 					childDOMRegion.documentRegion = nextRegion;
 					childDOMRegion.domNode = childDOMNode;
-					if (childDOMNode.getFirstStructuredDocumentRegion().equals(nextRegion)) {
+					if (nextRegion.equals(childDOMNode.getFirstStructuredDocumentRegion())) {
 						// format children. pass in child constraints
 						childDOMRegion = formatRegion(textEdit, formatRange, childrenConstraints, childDOMRegion, previousDocumentRegion);
 					}