summaryrefslogtreecommitdiffstats
path: root/pkg/gui/branches_panel.go
diff options
context:
space:
mode:
authorJesse Duffield <jessedduffield@gmail.com>2021-12-29 11:37:15 +1100
committerJesse Duffield <jessedduffield@gmail.com>2022-01-04 09:07:15 +1100
commit18ab08612687b34ccfccd0b8d12d8d73e38b8857 (patch)
tree268bb3b9872e20c75d81102c6ebffdea0e6d6819 /pkg/gui/branches_panel.go
parentb4c078d565af69bcb2f46adc20e528e53ae32908 (diff)
introduce Common struct for passing around common stuff
Diffstat (limited to 'pkg/gui/branches_panel.go')
-rw-r--r--pkg/gui/branches_panel.go10
1 files changed, 6 insertions, 4 deletions
diff --git a/pkg/gui/branches_panel.go b/pkg/gui/branches_panel.go
index 7b712b2ba..8dff14ac1 100644
--- a/pkg/gui/branches_panel.go
+++ b/pkg/gui/branches_panel.go
@@ -61,10 +61,12 @@ func (gui *Gui) refreshBranches() {
}
}
- builder, err := commands.NewBranchListBuilder(gui.Log, gui.GitCommand, reflogCommits)
- if err != nil {
- _ = gui.surfaceError(err)
- }
+ builder := commands.NewBranchListBuilder(
+ gui.Common,
+ gui.GitCommand.GetRawBranches,
+ gui.GitCommand.CurrentBranchName,
+ reflogCommits,
+ )
gui.State.Branches = builder.Build()
if err := gui.postRefreshUpdate(gui.State.Contexts.Branches); err != nil {