category and logout fiexes
This commit is contained in:
@@ -8,7 +8,9 @@ export async function listCategories() {
|
||||
const headers = token ? { Authorization: `Bearer ${token}` } : {};
|
||||
|
||||
try {
|
||||
const response = await axios.get(`${API_URL}/vars/categories`, { headers: headers });
|
||||
const response = await axios.get(`${API_URL}/vars/categories`, {
|
||||
headers: headers,
|
||||
});
|
||||
return response.data;
|
||||
} catch (err) {
|
||||
console.error("Nie udało się pobrać listy kategorii.", err.response.status);
|
||||
|
||||
@@ -28,7 +28,6 @@ export async function getWishlist() {
|
||||
|
||||
try {
|
||||
const response = await axios.get(`${API_URL}/`, { headers });
|
||||
console.log("Wishlist response:", response.data);
|
||||
return response.data;
|
||||
} catch (error) {
|
||||
console.error("Error fetching wishlist:", error);
|
||||
|
||||
Reference in New Issue
Block a user