jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mdue...@apache.org
Subject svn commit: r1331482 - /jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/TreeImpl.java
Date Fri, 27 Apr 2012 16:01:29 GMT
Author: mduerig
Date: Fri Apr 27 16:01:29 2012
New Revision: 1331482

URL: http://svn.apache.org/viewvc?rev=1331482&view=rev
Log:
minor simplification

Modified:
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/TreeImpl.java

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/TreeImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/TreeImpl.java?rev=1331482&r1=1331481&r2=1331482&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/TreeImpl.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/TreeImpl.java
Fri Apr 27 16:01:29 2012
@@ -237,13 +237,16 @@ public class TreeImpl implements Tree {
     @Override
     public TreeImpl getChild(String name) {
         NodeStateBuilder childBuilder = builder.getChildBuilder(name);
-        NodeState childBaseState = baseState == null
-            ? null
-            : baseState.getChildNode(name);
-
-        return childBuilder == null
-            ? null
-            : new TreeImpl(store, childBaseState, childBuilder, this, name, listener);
+        if (childBuilder == null) {
+            return null;
+        }
+        else {
+            NodeState childBaseState = baseState == null
+                    ? null
+                    : baseState.getChildNode(name);
+
+            return new TreeImpl(store, childBaseState, childBuilder, this, name, listener);
+        }
     }
 
     @Override



Mime
View raw message