diff --git a/src/frontend/src/contexts/typesContext.tsx b/src/frontend/src/contexts/typesContext.tsx index d08af1857..672295f26 100644 --- a/src/frontend/src/contexts/typesContext.tsx +++ b/src/frontend/src/contexts/typesContext.tsx @@ -42,7 +42,7 @@ export function TypesProvider({ children }: { children: ReactNode }) { const [data, setData] = useState({}); const [fetchError, setFetchError] = useState(false); const { setLoading } = useContext(alertContext); - const { getAuthentication, autoLogin, userData } = useContext(AuthContext); + const { getAuthentication } = useContext(AuthContext); const [getFilterEdge, setFilterEdge] = useState([]); useEffect(() => { @@ -50,7 +50,7 @@ export function TypesProvider({ children }: { children: ReactNode }) { if (getAuthentication() === true) { getTypes(); } - }, [getAuthentication(), autoLogin, userData]); + }, [getAuthentication()]); async function getTypes(): Promise { // We will keep a flag to handle the case where the component is unmounted before the API call resolves. diff --git a/src/frontend/src/pages/MainPage/components/components/index.tsx b/src/frontend/src/pages/MainPage/components/components/index.tsx index 280668700..7ea4825bf 100644 --- a/src/frontend/src/pages/MainPage/components/components/index.tsx +++ b/src/frontend/src/pages/MainPage/components/components/index.tsx @@ -51,7 +51,6 @@ export default function ComponentsComponent({ const start = (pageIndex - 1) * pageSize; const end = start + pageSize; setData(allData.slice(start, end)); - console.log(allData); }, [pageIndex, pageSize, allData]); const [data, setData] = useState([]);