fix: hardcoded localhost → VITE_BACKEND_URL

This commit is contained in:
2026-03-15 17:43:20 +01:00
parent be9c28b59d
commit e0bd6a2c4b

View File

@@ -23,7 +23,7 @@ import React, {
try { try {
const decodedPayload = jwtDecode(jwtToken); const decodedPayload = jwtDecode(jwtToken);
const res = await axios.get( const res = await axios.get(
`http://localhost:3310/api/users/${decodedPayload.user}` `${import.meta.env.VITE_BACKEND_URL}/api/users/${decodedPayload.user}`
); );
setUser(res.data); setUser(res.data);
} catch (error) { } catch (error) {