@@ -142,7 +142,7 @@
// After successful deletion, update the mediaData array and refresh the media list
// delete media from http://127.0.0.1:8090/api/collections/media/records/{id} with DELETE method
// check for response 204 and remove media from mediaData array
- fetch(`http://127.0.0.1:8090/api/collections/media/records/`+ mediaId, {
+ fetch(`/api/collections/media/records/`+ mediaId, {
method: "DELETE",
headers: {
"Content-Type": "application/json",
@@ -170,7 +170,7 @@
// find the input with the id of index
let durationInput = Array.from(durationInputs).find(input => input.id === index.toString());
// PATCH request to update the duration of the media file /api/collections/media/records/:id
- fetch(`http://127.0.0.1:8090/api/collections/media/records/`+ index, {
+ fetch(`/api/collections/media/records/`+ index, {
method: "PATCH",
headers: {
"Content-Type": "application/json",