From 65859924c26ad52e4c1c3602bf5922e0ef8678a1 Mon Sep 17 00:00:00 2001 From: Navin Karkera Date: Wed, 11 Oct 2023 20:12:43 +0530 Subject: [PATCH] fix: await async saveSetting func to remove unwanted err msg (#610) --- src/pages-and-resources/progress/Settings.jsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pages-and-resources/progress/Settings.jsx b/src/pages-and-resources/progress/Settings.jsx index 39e12c4b3d..965f110b1b 100644 --- a/src/pages-and-resources/progress/Settings.jsx +++ b/src/pages-and-resources/progress/Settings.jsx @@ -12,8 +12,8 @@ const ProgressSettings = ({ intl, onClose }) => { const [disableProgressGraph, saveSetting] = useAppSetting('disableProgressGraph'); const showProgressGraphSetting = getConfig().ENABLE_PROGRESS_GRAPH_SETTINGS.toString().toLowerCase() === 'true'; - const handleSettingsSave = (values) => { - if (showProgressGraphSetting) { saveSetting(!values.enableProgressGraph); } + const handleSettingsSave = async (values) => { + if (showProgressGraphSetting) { await saveSetting(!values.enableProgressGraph); } }; return (