Skip to content

Commit 3b601b5

Browse files
authored
Remove Prototype.js code (#101)
1 parent be9fd68 commit 3b601b5

File tree

1 file changed

+1
-10
lines changed

1 file changed

+1
-10
lines changed

src/main/webapp/js/addrole.js

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -107,14 +107,5 @@ const sendPostRequest = (postUrl, json) => {
107107
}
108108
};
109109

110-
// this is really bad.
111-
// See https://github.com/jenkinsci/jenkins/blob/75468da366c1d257a51655dcbe952d55b8aeeb9c/war/src/main/js/util/jenkins.js#L22
112-
const oldPrototype = Array.prototype.toJSON;
113-
delete Array.prototype.toJSON;
114-
115-
try {
116-
xhr.send(JSON.stringify(json));
117-
} finally {
118-
Array.prototype.toJSON = oldPrototype;
119-
}
110+
xhr.send(JSON.stringify(json));
120111
};

0 commit comments

Comments
 (0)