abdera-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From veit...@apache.org
Subject svn commit: r1371887 - /abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMBuilder.java
Date Sat, 11 Aug 2012 08:34:41 GMT
Author: veithen
Date: Sat Aug 11 08:34:41 2012
New Revision: 1371887

URL: http://svn.apache.org/viewvc?rev=1371887&view=rev
Log:
Removed unnecessary null checks.

Modified:
    abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMBuilder.java

Modified: abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMBuilder.java
URL: http://svn.apache.org/viewvc/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMBuilder.java?rev=1371887&r1=1371886&r2=1371887&view=diff
==============================================================================
--- abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMBuilder.java (original)
+++ abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMBuilder.java Sat
Aug 11 08:34:41 2012
@@ -87,10 +87,8 @@ public class FOMBuilder extends StAXOMBu
             node = constructNode(null, elementName);
         } else if (lastNode.isComplete()) {
             node = constructNode((OMContainer)lastNode.getParent(), elementName);
-            if (node != null) {
-                ((OMNodeEx)lastNode).setNextOMSibling(node);
-                ((OMNodeEx)node).setPreviousOMSibling(lastNode);
-            }
+            ((OMNodeEx)lastNode).setNextOMSibling(node);
+            ((OMNodeEx)node).setPreviousOMSibling(lastNode);
         } else {
             OMElement e = (OMElement)lastNode;
             node = constructNode((OMElement)lastNode, elementName);
@@ -265,10 +263,8 @@ public class FOMBuilder extends StAXOMBu
         if (element == null) {
             element = new FOMElement(qname, parent, fomfactory, this);
         }
-        if (element != null) {
-            this.processNamespaceData(element);
-            processAttributes(element);
-        }
+        this.processNamespaceData(element);
+        processAttributes(element);
         return element;
     }
 



Mime
View raw message