Stop gating the homepage on the settings request (#82629)
Claude-Session: https://claude.ai/code/session_017G1dfFTeS2dqcoPMcVqafU Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,11 +1,9 @@
|
||||
import { skipToken, useGetDashboardQuery } from "metabase/api";
|
||||
import { useSelector } from "metabase/redux";
|
||||
import { getCustomHomePageDashboardId } from "metabase/selectors/app";
|
||||
import { getSettingsLoading } from "metabase/settings";
|
||||
|
||||
export const useHomepageDashboard = () => {
|
||||
const dashboardId = useSelector(getCustomHomePageDashboardId);
|
||||
const isLoadingSettings = useSelector(getSettingsLoading);
|
||||
|
||||
const { data: dashboard, isLoading: isLoadingDashboard } =
|
||||
useGetDashboardQuery(dashboardId ? { id: dashboardId } : skipToken);
|
||||
@@ -13,6 +11,6 @@ export const useHomepageDashboard = () => {
|
||||
return {
|
||||
dashboardId,
|
||||
dashboard,
|
||||
isLoading: isLoadingDashboard || isLoadingSettings,
|
||||
isLoading: isLoadingDashboard,
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user