We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a73e7f6 commit 00b9017Copy full SHA for 00b9017
github-pullrequest-plugin/src/main/webapp/scripts/featureButton.js
@@ -1,10 +1,12 @@
1
function callFeature(button, answerPlaceId, parameters) {
2
- new Ajax.Request(button.action, {
+ fetch(button.action, {
3
method: "post",
4
- parameters: parameters,
5
- onComplete: function (rsp) {
6
- answerPlaceId.innerHTML = rsp.responseText;
7
- }
+ headers: crumb.wrap({}),
+ body: new URLSearchParams(parameters),
+ }).then(rsp => {
+ rsp.text().then((responseText) => {
8
+ answerPlaceId.innerHTML = responseText;
9
+ });
10
});
11
return false;
12
}
0 commit comments