From 341ac14839476de8468e6a3dec4cd92383ffc3f0 Mon Sep 17 00:00:00 2001 From: TropiiDev Date: Sat, 26 Apr 2025 21:13:44 -0400 Subject: [PATCH] Fix a bug with URL in user page v0.0.9 --- assets/js/user.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/assets/js/user.js b/assets/js/user.js index 794b704..47bab5a 100644 --- a/assets/js/user.js +++ b/assets/js/user.js @@ -73,7 +73,7 @@ const loadUserTasks = () => { } const getUserTasks = (userToken) => { - const res = fetch(`${localhostUrl}/users/me`, { + const res = fetch(`${url}/users/me`, { headers: {Authorization: `Bearer ${userToken}`} }); @@ -112,7 +112,7 @@ const updateTask = (userToken, taskTitle, taskDescription, completedStatus) => { console.log(body); console.log(taskDescription); - const res = fetch(`${localhostUrl}/user/update-tasks`, { + const res = fetch(`${url}/user/update-tasks`, { method: "PATCH", headers: {Authorization: `Bearer ${userToken}`, "Content-type": "application/json"}, body: body