diff --git a/packages/pl-fe/src/components/modal-root.tsx b/packages/pl-fe/src/components/modal-root.tsx index be0eb10fc..c3217fc4c 100644 --- a/packages/pl-fe/src/components/modal-root.tsx +++ b/packages/pl-fe/src/components/modal-root.tsx @@ -139,9 +139,9 @@ const ModalRoot: React.FC = ({ children, onCancel, onClose, type }) }; const ensureHistoryBuffer = () => { - const { pathname, state } = history.location; + const { state } = history.location; if (!state || (state as any).plFeModalKey !== modalHistoryKey.current) { - history.push(pathname, { ...(state as any), plFeModalKey: modalHistoryKey.current }); + history.push(history.location, { ...(state as any), plFeModalKey: modalHistoryKey.current }); } };