From 669935c08f7ad3b6c31647884e25c8f60e5adebc Mon Sep 17 00:00:00 2001 From: Bilal MEDDAH Date: Mon, 17 Jul 2023 11:06:25 +0200 Subject: [PATCH] fix: use location from react-router instead of window --- .../DataExplorerGraphFlowNavigationStack/useNavigationStack.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/shared/organisms/DataExplorerGraphFlowNavigationStack/useNavigationStack.ts b/src/shared/organisms/DataExplorerGraphFlowNavigationStack/useNavigationStack.ts index 5046c5515..a03c45b2c 100644 --- a/src/shared/organisms/DataExplorerGraphFlowNavigationStack/useNavigationStack.ts +++ b/src/shared/organisms/DataExplorerGraphFlowNavigationStack/useNavigationStack.ts @@ -1,5 +1,5 @@ import { useDispatch, useSelector } from 'react-redux'; -import { useHistory } from 'react-router'; +import { useHistory, useLocation } from 'react-router'; import { RootState } from '../../store/reducers'; import { DATA_EXPLORER_GRAPH_FLOW_DIGEST, @@ -13,6 +13,7 @@ import { const useNavigationStackManager = () => { const dispatch = useDispatch(); const history = useHistory(); + const location = useLocation(); const { rightNodes, leftNodes, referer } = useSelector( (state: RootState) => state.dataExplorer );