Fix undefined state from react-router-dom. (#6293)

Fix state not well typed from react-router-dom, it can be undefined and
we should check for that.
This commit is contained in:
Lucas Bordeau
2024-07-16 17:10:19 +02:00
committed by GitHub
parent 9711a430de
commit 8833a38db5

View File

@ -115,7 +115,7 @@ export const useRecordShowPagePagination = (
const { state } = useLocation();
const cursorFromIndexPage = state.cursor;
const cursorFromIndexPage = state?.cursor;
const { loading: loadingCurrentRecord, pageInfo: currentRecordsPageInfo } =
useFindManyRecords({