Need location.search too because Search page is using it

This commit is contained in:
Lim Chee Aun 2023-02-11 17:58:49 +08:00
parent 27c7a2dee9
commit 9401fc38e1

View file

@ -322,7 +322,8 @@ function StatusPage() {
); );
const closeLink = useMemo(() => { const closeLink = useMemo(() => {
const pathname = snapStates.prevLocation?.pathname; const { prevLocation } = snapStates;
const pathname = prevLocation?.pathname + (prevLocation?.search || '');
if ( if (
!pathname || !pathname ||
matchPath('/:instance/s/:id', pathname) || matchPath('/:instance/s/:id', pathname) ||