From 1803908735060ec3dc7164da2b87c223ec044a0d Mon Sep 17 00:00:00 2001 From: SleeplessOne1917 Date: Thu, 28 Sep 2023 06:12:15 -0400 Subject: [PATCH] fix: Fix bug where old settings would linger on page until browser refresh --- src/shared/components/person/settings.tsx | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/shared/components/person/settings.tsx b/src/shared/components/person/settings.tsx index a52798ac..7fab421e 100644 --- a/src/shared/components/person/settings.tsx +++ b/src/shared/components/person/settings.tsx @@ -1376,6 +1376,17 @@ export class Settings extends Component { res: saveRes.data, showToast: false, }); + + const siteRes = await HttpService.client.getSite(); + + if (siteRes.state === "success") { + i.setState({ + siteRes: siteRes.data, + }); + + UserService.Instance.myUserInfo = siteRes.data.my_user; + } + toast(I18NextService.i18n.t("saved")); window.scrollTo(0, 0); }