Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordonald.g.dunne2018-10-18 18:43:45 +0000
committerDonald Dunne2018-10-18 19:03:36 +0000
commitcfaab695848f13333d538b4506df8b68cecc947a (patch)
tree8c7e0e2efde0e4af98ed0a450153389d8369d4ea
parent6b376beb0bf03e99919161b01acd0540a8a35d3a (diff)
downloadorg.eclipse.osee-cfaab695848f13333d538b4506df8b68cecc947a.tar.gz
org.eclipse.osee-cfaab695848f13333d538b4506df8b68cecc947a.tar.xz
org.eclipse.osee-cfaab695848f13333d538b4506df8b68cecc947a.zip
bug[ats_TW11473]: Fix 0.25.4 ViewApplicabilityUtil.isBranchOfProductLine performance
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/branch/ViewApplicabilityUtil.java5
1 files changed, 1 insertions, 4 deletions
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/branch/ViewApplicabilityUtil.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/branch/ViewApplicabilityUtil.java
index 201d1e0f391..ecc4ccc169c 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/branch/ViewApplicabilityUtil.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/branch/ViewApplicabilityUtil.java
@@ -23,7 +23,6 @@ import org.eclipse.osee.framework.core.data.ArtifactId;
import org.eclipse.osee.framework.core.data.ArtifactToken;
import org.eclipse.osee.framework.core.data.BranchId;
import org.eclipse.osee.framework.core.data.BranchViewData;
-import org.eclipse.osee.framework.core.enums.CoreArtifactTypes;
import org.eclipse.osee.framework.core.enums.PermissionEnum;
import org.eclipse.osee.framework.core.exception.ArtifactDoesNotExist;
import org.eclipse.osee.framework.core.model.access.PermissionStatus;
@@ -128,9 +127,7 @@ public class ViewApplicabilityUtil {
}
public static boolean isBranchOfProductLine(BranchId branch) {
- int count = ArtifactQuery.createQueryBuilder(branch).andIsOfType(CoreArtifactTypes.FeatureDefinition).getCount();
- return count > 0;
-
+ return !getBranchViews(branch).isEmpty();
}
public static BranchId getParentBranch(BranchId branch) {

Back to the top