diff --git a/pkg/commands/oscommands/cmd_obj_builder.go b/pkg/commands/oscommands/cmd_obj_builder.go index a493ae651..ef27bd4c0 100644 --- a/pkg/commands/oscommands/cmd_obj_builder.go +++ b/pkg/commands/oscommands/cmd_obj_builder.go @@ -52,7 +52,7 @@ func (self *CmdObjBuilder) NewFromArgs(args []string) ICmdObj { } func (self *CmdObjBuilder) NewShell(commandStr string) ICmdObj { - quotedCommand := "" + var quotedCommand string // Windows does not seem to like quotes around the command if self.platform.OS == "windows" { quotedCommand = strings.NewReplacer( diff --git a/pkg/gui/recent_repos_panel.go b/pkg/gui/recent_repos_panel.go index a301d0447..b10a83078 100644 --- a/pkg/gui/recent_repos_panel.go +++ b/pkg/gui/recent_repos_panel.go @@ -23,7 +23,7 @@ func (gui *Gui) getCurrentBranch(path string) string { if err == nil { content := strings.TrimSpace(string(headFile)) refsPrefix := "ref: refs/heads/" - branchDisplay := "" + var branchDisplay string if strings.HasPrefix(content, refsPrefix) { // is a branch branchDisplay = strings.TrimPrefix(content, refsPrefix)