diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2020-10-07 22:21:15 +1100 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2020-10-10 00:23:01 +1100 |
commit | 9011271a014025c514adf72b1d1ee69fbc7f3373 (patch) | |
tree | 56aa883701820fd538289a58c628c065cde971a2 /pkg/gui/remotes_panel.go | |
parent | 777ec0b36c5e7b7ba67766ec1bef3ebb3d60f599 (diff) |
fix another panic error
Diffstat (limited to 'pkg/gui/remotes_panel.go')
-rw-r--r-- | pkg/gui/remotes_panel.go | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/pkg/gui/remotes_panel.go b/pkg/gui/remotes_panel.go index 9d1450003..f3c984d78 100644 --- a/pkg/gui/remotes_panel.go +++ b/pkg/gui/remotes_panel.go @@ -58,7 +58,12 @@ func (gui *Gui) refreshRemotes() error { } } - return gui.postRefreshUpdate(gui.mustContextForContextKey(gui.getBranchesView().Context)) + branchesView := gui.getBranchesView() + if branchesView != nil { + return gui.postRefreshUpdate(gui.mustContextForContextKey(branchesView.Context)) + } + + return nil } func (gui *Gui) handleRemoteEnter() error { |