web fixes
This commit is contained in:
@@ -15,14 +15,11 @@ export default function DisplayNav() {
|
||||
const [menuOpen, setMenuOpen] = useState(false);
|
||||
|
||||
useEffect(() => {
|
||||
if (!token) return;
|
||||
fetch("/api/v1/stores?size=100", {
|
||||
headers: { Authorization: `Bearer ${token}` },
|
||||
})
|
||||
fetch("/api/v1/stores?size=100")
|
||||
.then((r) => (r.ok ? r.json() : null))
|
||||
.then((data) => { if (data) setStores(data.content ?? []); })
|
||||
.catch(() => {});
|
||||
}, [token]);
|
||||
}, []);
|
||||
|
||||
function handleLogout() {
|
||||
logout();
|
||||
|
||||
Reference in New Issue
Block a user