From c6dae02925ae4a970210125b06f3fb9458f1d3fd Mon Sep 17 00:00:00 2001 From: Connor Kuehl Date: Thu, 14 Apr 2022 16:30:23 -0500 Subject: main: remove unnecessary pointer dereference Calling a method on a pointer will dereference it automatically. Signed-off-by: Connor Kuehl Acked-by: Robin Jarry --- aerc.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'aerc.go') diff --git a/aerc.go b/aerc.go index 9d93a501..f9a19a31 100644 --- a/aerc.go +++ b/aerc.go @@ -58,7 +58,7 @@ func getCommands(selected libui.Drawable) []*commands.Commands { } func execCommand(aerc *widgets.Aerc, ui *libui.UI, cmd []string) error { - cmds := getCommands((*aerc).SelectedTab()) + cmds := getCommands(aerc.SelectedTab()) for i, set := range cmds { err := set.ExecuteCommand(aerc, cmd) if _, ok := err.(commands.NoSuchCommand); ok { @@ -80,7 +80,7 @@ func execCommand(aerc *widgets.Aerc, ui *libui.UI, cmd []string) error { func getCompletions(aerc *widgets.Aerc, cmd string) []string { var completions []string - for _, set := range getCommands((*aerc).SelectedTab()) { + for _, set := range getCommands(aerc.SelectedTab()) { completions = append(completions, set.GetCompletions(aerc, cmd)...) } sort.Strings(completions) -- cgit