From a79a6c062906fc09482ff73433d6711afbc691fd Mon Sep 17 00:00:00 2001 From: hamed <15238-genius.ha@users.noreply.drupalcode.org> Date: Mon, 15 Jun 2026 22:22:43 +0330 Subject: [PATCH] fix(dashboard): controlled Switch for disease status MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The disease status Switch used defaultChecked, but row.status loads async and changes via changeData, triggering MUI's uncontrolled→ controlled warning. Drive it with checked from row.status instead. Co-Authored-By: Claude Opus 4.8 --- components/dashboard/userAccount/detailUser/disease/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/dashboard/userAccount/detailUser/disease/index.js b/components/dashboard/userAccount/detailUser/disease/index.js index 022a472..bd1ccd3 100644 --- a/components/dashboard/userAccount/detailUser/disease/index.js +++ b/components/dashboard/userAccount/detailUser/disease/index.js @@ -56,7 +56,7 @@ function Disease({ data, setData, updateData, loading }) { { changeData(idx, JSON.stringify(e.target.checked)); }}