Skip to content
This repository was archived by the owner on Sep 30, 2025. It is now read-only.

Commit 270231e

Browse files
author
Radislav Berkovich
committed
tech : code climate fixes
1 parent c4b8eac commit 270231e

File tree

1 file changed

+8
-10
lines changed

1 file changed

+8
-10
lines changed

src/main/java/com/microfocus/application/automation/tools/octane/model/processors/projects/AbstractProjectProcessor.java

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -102,17 +102,15 @@ public void cancelBuild(Cause cause, ParametersAction parametersAction) {
102102
project.getBuilds().forEach(build -> {
103103
if (build instanceof AbstractBuild) {
104104
AbstractBuild aBuild = (AbstractBuild) build;
105-
if(aBuild.isBuilding()) {
106-
aBuild.getActions(ParametersAction.class).forEach(action -> {
107-
if (checkSuiteIdParamsExistAndEqual(action, suiteId, suiteRunId)) {
108-
try {
109-
aBuild.doStop();
110-
} catch (Exception e) {
111-
logger.warn("Failed to stop build '" + aBuild.getDisplayName() + "' :" + e.getMessage(), e);
112-
}
105+
aBuild.getActions(ParametersAction.class).forEach(action -> {
106+
if (checkSuiteIdParamsExistAndEqual(action, suiteId, suiteRunId)) {
107+
try {
108+
aBuild.doStop();
109+
} catch (Exception e) {
110+
logger.warn("Failed to stop build '" + aBuild.getDisplayName() + "' :" + e.getMessage(), e);
113111
}
114-
});
115-
}
112+
}
113+
});
116114
}
117115
});
118116
} else {

0 commit comments

Comments
 (0)