Update remaining deprecated API URLs, GH-368

This commit is contained in:
krateng 2025-02-03 04:04:48 +01:00
parent 76c013e130
commit cc64c894f0
4 changed files with 6 additions and 6 deletions

View File

@ -15,7 +15,7 @@
var xhttp = new XMLHttpRequest();
xhttp.open("POST","/api/newrule?", true);
xhttp.open("POST","/apis/mlj_1/newrule?", true);
xhttp.send(keys);
e = arguments[0];
line = e.parentNode;
@ -25,7 +25,7 @@
function fullrebuild() {
var xhttp = new XMLHttpRequest();
xhttp.open("POST","/api/rebuild", true);
xhttp.open("POST","/apis/mlj_1/rebuild", true);
xhttp.send();
window.location = "/wait";

View File

@ -24,7 +24,7 @@
keys = "filename=" + encodeURIComponent(filename);
console.log(keys);
var xhttp = new XMLHttpRequest();
xhttp.open("POST","/api/importrules", true);
xhttp.open("POST","/apis/mlj_1/importrules", true);
xhttp.send(keys);
e.innerHTML = e.innerHTML.replace("Add","Remove");
@ -36,7 +36,7 @@
keys = "remove&filename=" + encodeURIComponent(filename);
var xhttp = new XMLHttpRequest();
xhttp.open("POST","/api/importrules", true);
xhttp.open("POST","/apis/mlj_1/importrules", true);
xhttp.send(keys);
e.innerHTML = e.innerHTML.replace("Remove","Add");

View File

@ -186,7 +186,7 @@ function search_manualscrobbling(searchfield) {
else {
xhttp = new XMLHttpRequest();
xhttp.onreadystatechange = searchresult_manualscrobbling;
xhttp.open("GET","/api/search?max=5&query=" + encodeURIComponent(txt), true);
xhttp.open("GET","/apis/mlj_1/search?max=5&query=" + encodeURIComponent(txt), true);
xhttp.send();
}
}

View File

@ -1,3 +1,3 @@
function upload(encodedentity,b64) {
neo.xhttprequest("/api/addpicture?" + encodedentity,{"b64":b64},"POST")
neo.xhttprequest("/apis/mlj_1/addpicture?" + encodedentity,{"b64":b64},"POST")
}