This commit is contained in:
Mohit kalshan 2025-03-03 17:33:08 +05:30
parent 4c63007072
commit 01dcb50d01
2 changed files with 2 additions and 2 deletions

View file

@ -45,7 +45,7 @@ export const loginUser = createAsyncThunk<
//use below commented endpoint if using deployed backend........
// const response = await http.post("admin/login", {
const response = await http.post("admin/login", {
const response = await http.post("/login", {
email,
password,
});

View file

@ -26,7 +26,7 @@ export const fetchAdminProfile = createAsyncThunk<
const token = localStorage?.getItem("authToken");
if (!token) throw new Error("No token found");
const response = await http.get("/auth/profile");
const response = await http.get("/profile");
if (!response.data?.data) throw new Error("Invalid API response");