mirror of
https://github.com/instructkr/claude-code.git
synced 2026-05-28 16:36:45 +00:00
fix(#727): add has_upstream bool to branch_freshness JSON to disambiguate fresh:null-no-upstream from fresh:null-unknown
This commit is contained in:
@@ -3326,6 +3326,10 @@ impl BranchFreshness {
|
||||
fn json_value(&self) -> serde_json::Value {
|
||||
json!({
|
||||
"upstream": self.upstream,
|
||||
// #727: has_upstream disambiguates fresh:null-because-no-upstream
|
||||
// from fresh:null-because-unavailable; automation should check
|
||||
// has_upstream before branching on fresh.
|
||||
"has_upstream": self.upstream.is_some(),
|
||||
"ahead": self.ahead,
|
||||
"behind": self.behind,
|
||||
"fresh": self.fresh,
|
||||
|
||||
Reference in New Issue
Block a user