use getKey in doChangeSupportedSyndicate
All checks were successful
Build / build (18) (pull_request) Successful in 41s
Build / build (22) (pull_request) Successful in 54s
Build / build (20) (pull_request) Successful in 50s

This commit is contained in:
AMelonInsideLemon 2025-03-07 01:35:27 +01:00
parent 83031061d2
commit a2fac3635b

View File

@ -1147,10 +1147,7 @@ function doImport() {
}
function doChangeSupportedSyndicate() {
const uniqueName =
[...document.querySelectorAll("#datalist-Syndicates option")]
.find(option => option.value === document.getElementById("changeSyndicate").value)
?.getAttribute("data-key") || "";
const uniqueName = getKey(document.getElementById("changeSyndicate"));
revalidateAuthz(() => {
$.get("/api/setSupportedSyndicate.php?" + window.authz + "&syndicate=" + uniqueName).done(function () {