diff --git a/apps/web/src/components/BranchToolbar.tsx b/apps/web/src/components/BranchToolbar.tsx index 9fd8774d0fe31c00efe0c696ed378bffc3843d6f..2379d0b91cc0a75d2d7325ae94e2fe01f712f8b0 100644 --- a/apps/web/src/components/BranchToolbar.tsx +++ b/apps/web/src/components/BranchToolbar.tsx @@ -37,7 +37,9 @@ export default function BranchToolbar({ envMode, onEnvModeChange, envLocked }: B }); const branches = branchesQuery.data?.branches ?? []; - const isRepo = branchesQuery.data?.isRepo ?? false; + // Default to true while loading — showing "Initialize git" during a fetch is wrong, + // and worktrees are inherently git repos. + const isRepo = branchesQuery.data?.isRepo ?? !branchesQuery.isLoading; // ── Mutations ─────────────────────────────────────────────────────────