Phase 0: Fix AppSidebar useEffect for module settings loading

This commit is contained in:
IGNY8 VPS (Salman)
2025-11-16 18:48:45 +00:00
parent 9b3fb25bc9
commit 5842ca2dfc

View File

@@ -282,6 +282,14 @@ const AppSidebar: React.FC = () => {
: menuSections;
}, [isAwsAdminAccount, menuSections, adminSection]);
// Load module enable settings on mount
useEffect(() => {
const { loadModuleEnableSettings } = useSettingsStore.getState();
if (!moduleEnableSettings) {
loadModuleEnableSettings();
}
}, [moduleEnableSettings]);
useEffect(() => {
const currentPath = location.pathname;
let foundMatch = false;