diff --git a/frontend/app/components/shared/SessionsTabOverview/components/SessionList/SessionList.tsx b/frontend/app/components/shared/SessionsTabOverview/components/SessionList/SessionList.tsx index 649e9f98a..de62c044a 100644 --- a/frontend/app/components/shared/SessionsTabOverview/components/SessionList/SessionList.tsx +++ b/frontend/app/components/shared/SessionsTabOverview/components/SessionList/SessionList.tsx @@ -110,12 +110,6 @@ function SessionList() { } }, [statusData, siteId]); - // useEffect(() => { - // if (siteId) { - // void searchStore.fetchSessions(); - // } - // }, [siteId]); - useEffect(() => { const id = setInterval(() => { if (!document.hidden) { @@ -130,12 +124,6 @@ function SessionList() { const { scrollY } = searchStore; window.scrollTo(0, scrollY); - // if (total === 0 && !loading && !hasNoRecordings) { - // setTimeout(() => { - // void searchStore.fetchSessions(); - // }, 100); - // } - return () => { searchStore.setScrollPosition(window.scrollY); }; @@ -205,7 +193,9 @@ function SessionList() { className="mt-4" icon="arrow-repeat" iconSize={20} - onClick={() => searchStore.fetchSessions(true)} + onClick={() => { + void searchStore.fetchSessions(true, isBookmark); + }} > Refresh diff --git a/frontend/app/mstore/userStore.ts b/frontend/app/mstore/userStore.ts index 11e792ac4..3fb7db13e 100644 --- a/frontend/app/mstore/userStore.ts +++ b/frontend/app/mstore/userStore.ts @@ -496,7 +496,10 @@ class UserStore { try { await userService.updateClient(params); runInAction(() => { - this.client = new Client({ ...this.client, ...params }); + Object.keys(params).forEach((key) => { + this.client[key] = params[key]; + this.account[key] = params[key]; + }) }); } catch (error) { // TODO error handling