diff options
Diffstat (limited to 'pkg/gui/status_panel.go')
-rw-r--r-- | pkg/gui/status_panel.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/pkg/gui/status_panel.go b/pkg/gui/status_panel.go index 2532cc96c..1f23ae6ec 100644 --- a/pkg/gui/status_panel.go +++ b/pkg/gui/status_panel.go @@ -67,6 +67,10 @@ func (gui *Gui) handleStatusClick(g *gocui.Gui, v *gocui.View) error { } currentBranch := gui.currentBranch() + if currentBranch == nil { + // need to wait for branches to refresh + return nil + } if err := gui.switchContext(gui.Contexts.Status.Context); err != nil { return err |