Add client-side user setting for agent commit attribution (#9323)

This commit is contained in:
lucieleblanc
2026-04-28 18:33:15 -04:00
committed by GitHub
parent 929944198c
commit 389716a905
11 changed files with 582 additions and 27 deletions
+10
View File
@@ -1456,6 +1456,16 @@ impl UserWorkspaces {
}
}
/// Returns the team-level agent attribution setting.
///
/// Use this to decide whether the user's attribution toggle should be locked
/// (`Enable`/`Disable`) or editable (`RespectUserSetting`).
pub fn get_agent_attribution_setting(&self) -> AdminEnablementSetting {
self.current_team()
.map(|team| team.organization_settings.enable_warp_attribution.clone())
.unwrap_or_default()
}
/// Returns only the organization-specific codebase context enablement setting.
/// Do not use this function to determine whether codebase context is generally enabled --
/// use `is_codebase_context_enabled` instead.