Skip to content

Commit cbcae2c

Browse files
committed
Fix BuildButtonColumn icon.js to check rsp.status === 201
This fix was missing from the current branch. It ensures that only 201 Created responses are treated as successful builds, preventing false 'Build scheduled' notifications when builds are rejected.
1 parent 9106f80 commit cbcae2c

File tree

1 file changed

+1
-1
lines changed
  • core/src/main/resources/hudson/views/BuildButtonColumn

1 file changed

+1
-1
lines changed

core/src/main/resources/hudson/views/BuildButtonColumn/icon.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Behaviour.specify(
1414
method: "post",
1515
headers: crumb.wrap({}),
1616
}).then((rsp) => {
17-
if (rsp.ok) {
17+
if (rsp.status === 201) {
1818
notificationBar.show(message, notificationBar.SUCCESS);
1919
} else {
2020
notificationBar.show(failure, notificationBar.ERROR);

0 commit comments

Comments
 (0)