From 9401fc38e1f23a1f5b35fdf0bd5adb583aeb25b6 Mon Sep 17 00:00:00 2001 From: Lim Chee Aun Date: Sat, 11 Feb 2023 17:58:49 +0800 Subject: [PATCH] Need location.search too because Search page is using it --- src/pages/status.jsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pages/status.jsx b/src/pages/status.jsx index 3a0cb699..c2cda99b 100644 --- a/src/pages/status.jsx +++ b/src/pages/status.jsx @@ -322,7 +322,8 @@ function StatusPage() { ); const closeLink = useMemo(() => { - const pathname = snapStates.prevLocation?.pathname; + const { prevLocation } = snapStates; + const pathname = prevLocation?.pathname + (prevLocation?.search || ''); if ( !pathname || matchPath('/:instance/s/:id', pathname) ||