diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2021-03-31 23:55:06 +1100 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2021-04-02 11:00:15 +1100 |
commit | 7d62f103e4a1b39b7e8fbd0e1f39815c525cd588 (patch) | |
tree | 83e331beeee07d066c76580e044234f18063a0a7 /pkg/gui/remotes_panel.go | |
parent | 9e85d37fb949bbc83f28cb079f2ac4b45ae895ce (diff) |
big refactor to give our enums actual types
Diffstat (limited to 'pkg/gui/remotes_panel.go')
-rw-r--r-- | pkg/gui/remotes_panel.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/pkg/gui/remotes_panel.go b/pkg/gui/remotes_panel.go index 2426c817a..d99bcbb08 100644 --- a/pkg/gui/remotes_panel.go +++ b/pkg/gui/remotes_panel.go @@ -94,7 +94,7 @@ func (gui *Gui) handleAddRemote(g *gocui.Gui, v *gocui.View) error { if err := gui.GitCommand.AddRemote(remoteName, remoteUrl); err != nil { return err } - return gui.refreshSidePanels(refreshOptions{scope: []int{REMOTES}}) + return gui.refreshSidePanels(refreshOptions{scope: []RefreshableView{REMOTES}}) }, }) }, @@ -116,7 +116,7 @@ func (gui *Gui) handleRemoveRemote(g *gocui.Gui, v *gocui.View) error { return gui.surfaceError(err) } - return gui.refreshSidePanels(refreshOptions{scope: []int{BRANCHES, REMOTES}}) + return gui.refreshSidePanels(refreshOptions{scope: []RefreshableView{BRANCHES, REMOTES}}) }, }) } @@ -164,7 +164,7 @@ func (gui *Gui) handleEditRemote(g *gocui.Gui, v *gocui.View) error { if err := gui.GitCommand.UpdateRemoteUrl(updatedRemoteName, updatedRemoteUrl); err != nil { return gui.surfaceError(err) } - return gui.refreshSidePanels(refreshOptions{scope: []int{BRANCHES, REMOTES}}) + return gui.refreshSidePanels(refreshOptions{scope: []RefreshableView{BRANCHES, REMOTES}}) }, }) }, @@ -184,6 +184,6 @@ func (gui *Gui) handleFetchRemote(g *gocui.Gui, v *gocui.View) error { err := gui.GitCommand.FetchRemote(remote.Name, gui.promptUserForCredential) gui.handleCredentialsPopup(err) - return gui.refreshSidePanels(refreshOptions{scope: []int{BRANCHES, REMOTES}}) + return gui.refreshSidePanels(refreshOptions{scope: []RefreshableView{BRANCHES, REMOTES}}) }) } |