diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2020-08-16 17:45:12 +1000 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2020-08-23 14:29:18 +1000 |
commit | ed4574bda9f7f3b385f72cd5f7156d47bc28d0ea (patch) | |
tree | bf2eda757c3eaf56660d4efa538e4653315e8ea1 /pkg/gui/filtering_menu_panel.go | |
parent | c9ae54a8c8669483f8fbbb99ce4b139e204daa39 (diff) |
standardise getting selected item
Diffstat (limited to 'pkg/gui/filtering_menu_panel.go')
-rw-r--r-- | pkg/gui/filtering_menu_panel.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/gui/filtering_menu_panel.go b/pkg/gui/filtering_menu_panel.go index 526313345..f5781e072 100644 --- a/pkg/gui/filtering_menu_panel.go +++ b/pkg/gui/filtering_menu_panel.go @@ -15,8 +15,8 @@ func (gui *Gui) handleCreateFilteringMenuPanel(g *gocui.Gui, v *gocui.View) erro fileName := "" switch v.Name() { case "files": - file, err := gui.getSelectedFile() - if err == nil { + file := gui.getSelectedFile() + if file != nil { fileName = file.Name } case "commitFiles": |