Update API endpoints and navigation paths in admin templates
This commit is contained in:
@@ -98,7 +98,7 @@ async function sendAction(action) {
|
||||
if (!currentMedia?.id) return;
|
||||
|
||||
const token = getToken();
|
||||
const endpoint = `admin/api/${action}`;
|
||||
const endpoint = `api/${action}`;
|
||||
await fetch(endpoint, {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
@@ -130,7 +130,7 @@ function showMessage(text) {
|
||||
}
|
||||
|
||||
async function fetchMedia(token) {
|
||||
const res = await fetch('admin/api/getmedia', {
|
||||
const res = await fetch('api/getmedia', {
|
||||
method: 'GET',
|
||||
headers: { 'Authorization': 'Bearer ' + token }
|
||||
});
|
||||
|
Reference in New Issue
Block a user