[339136] Empty tag boolean elements are inputted incorrectly
diff --git a/plugins/org.eclipse.wst.common.emf/wtpemf/org/eclipse/wst/common/internal/emf/resource/EMF2DOMAdapterImpl.java b/plugins/org.eclipse.wst.common.emf/wtpemf/org/eclipse/wst/common/internal/emf/resource/EMF2DOMAdapterImpl.java
index 3fa734c..53f9169 100644
--- a/plugins/org.eclipse.wst.common.emf/wtpemf/org/eclipse/wst/common/internal/emf/resource/EMF2DOMAdapterImpl.java
+++ b/plugins/org.eclipse.wst.common.emf/wtpemf/org/eclipse/wst/common/internal/emf/resource/EMF2DOMAdapterImpl.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2003, 2007 IBM Corporation and others.
+ * Copyright (c) 2003, 2011 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -1286,7 +1286,11 @@
Text textNode = DOMUtilities.getChildTextNode(parent);
if (textNode != null) {
textNode.setData(text);
- } else {
+ } else if (text != null) {
+ /*
+ * https://bugs.eclipse.org/339136 - let's not create one if we
+ * really don't have to
+ */
textNode = createTextNode(parent.getOwnerDocument(), map, text);
if (!isEmptyTag((Element) parent)) {
DOMUtilities.insertBeforeNode(parent, textNode, null);