Skip to content

Commit

Permalink
Fix quality flaws
Browse files Browse the repository at this point in the history
  • Loading branch information
henryju committed Mar 29, 2022
1 parent 59f3b13 commit ed7aac5
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ public class VcsService {

public static final boolean IS_EGIT_5_12_BUNDLE_AVAILABLE;
static {
boolean result = false;
var result = false;
try {
Bundle egitBundle = Platform.getBundle("org.eclipse.egit.core");
var egitBundle = Platform.getBundle("org.eclipse.egit.core");
result = egitBundle != null && (egitBundle.getState() & (Bundle.ACTIVE | Bundle.STARTING | Bundle.RESOLVED)) != 0
&& egitBundle.getVersion().compareTo(new Version(5, 12, 0)) >= 0;
} catch (Throwable exception) {
Expand All @@ -53,9 +53,9 @@ public class VcsService {

public static final boolean IS_EGIT_UI_BUNDLE_AVAILABLE;
static {
boolean result = false;
var result = false;
try {
Bundle egitUiBundle = Platform.getBundle("org.eclipse.egit.ui");
var egitUiBundle = Platform.getBundle("org.eclipse.egit.ui");
result = egitUiBundle != null && (egitUiBundle.getState() & (Bundle.ACTIVE | Bundle.STARTING | Bundle.RESOLVED)) != 0;
} catch (Throwable exception) {
// Assume that it's not available.
Expand Down

0 comments on commit ed7aac5

Please sign in to comment.