diff options
Diffstat (limited to 'plugins/org.eclipse.osee.framework.ui.branch.graph/src/org/eclipse/osee/framework/ui/branch/graph/model/GraphLoader.java')
-rw-r--r-- | plugins/org.eclipse.osee.framework.ui.branch.graph/src/org/eclipse/osee/framework/ui/branch/graph/model/GraphLoader.java | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/plugins/org.eclipse.osee.framework.ui.branch.graph/src/org/eclipse/osee/framework/ui/branch/graph/model/GraphLoader.java b/plugins/org.eclipse.osee.framework.ui.branch.graph/src/org/eclipse/osee/framework/ui/branch/graph/model/GraphLoader.java index 7ed0a7ea3dc..e535f3854fb 100644 --- a/plugins/org.eclipse.osee.framework.ui.branch.graph/src/org/eclipse/osee/framework/ui/branch/graph/model/GraphLoader.java +++ b/plugins/org.eclipse.osee.framework.ui.branch.graph/src/org/eclipse/osee/framework/ui/branch/graph/model/GraphLoader.java @@ -106,11 +106,8 @@ public class GraphLoader { if (source != null) { connect(source, txModel); } else { - OseeLog.logf( - Activator.class, - Level.SEVERE, - "Invalid parent transaction id of [%s] for branch [%s]", parentTxId, - branchModel.getBranch()); + OseeLog.logf(Activator.class, Level.SEVERE, + "Invalid parent transaction id of [%s] for branch [%s]", parentTxId, branchModel.getBranch()); // StubBranchModel stubModel = graphCache.getStubBranchModel(); // TxModel stubTxModel = stubModel.addTx(parentTxId); // graphCache.addTxModel(stubTxModel); @@ -145,9 +142,8 @@ public class GraphLoader { private static List<TxData> getTxData(int queryId) throws OseeCoreException { List<TxData> txDatas = new ArrayList<TxData>(); - IOseeStatement chStmt = null; + IOseeStatement chStmt = ConnectionHandler.getStatement(); try { - chStmt = ConnectionHandler.getStatement(); chStmt.runPreparedQuery(GET_TRANSACTION_DATA, queryId); while (chStmt.next()) { Branch branch = BranchManager.getBranch(chStmt.getInt("branch_id")); @@ -158,9 +154,7 @@ public class GraphLoader { txDatas.add(txData); } } finally { - if (chStmt != null) { - chStmt.close(); - } + chStmt.close(); } return txDatas; } |