diff --git a/frontend/js/apicalls.js b/frontend/js/apicalls.js index c26274c8296f8fdd8a1a555faa381f393ec064df..e2b3fd60675f1819691f891b4ee17c3e3e040467 100644 --- a/frontend/js/apicalls.js +++ b/frontend/js/apicalls.js @@ -545,6 +545,7 @@ function deleteMultipleDatasets(oids, datatype) { xmlhttp.addEventListener("loadend", successfullyDeletedDataset); xmlhttp.open("DELETE", fullUrl); xmlhttp.setRequestHeader('Authorization', 'Bearer ' + window.sessionStorage.auth_token); + xmlhttp.setRequestHeader("Content-Type", "application/json"); // needs to be set explicitly, as the array is not recognized properly otherwise xmlhttp.send(JSON.stringify(oids)); $('#button-delete').prepend('<span class="spinner-border spinner-border-sm" role="status" aria-hidden="true" id="spinner"></span>'); disableMetadataButtons();