1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-02-03 13:21:56 +02:00

remove useless returned variable

This commit is contained in:
Anthony HAMON 2018-08-21 21:09:53 +02:00
parent 93ab892bdd
commit a5adfaee8a
2 changed files with 3 additions and 7 deletions

View File

@ -46,10 +46,7 @@ func NewApp(config config.AppConfigurer) (*App, error) {
}
var err error
app.Log = newLogger(config)
app.OSCommand, err = commands.NewOSCommand(app.Log)
if err != nil {
return app, err
}
app.OSCommand = commands.NewOSCommand(app.Log)
app.Tr = i18n.NewLocalizer(app.Log)

View File

@ -30,12 +30,11 @@ type OSCommand struct {
}
// NewOSCommand os command runner
func NewOSCommand(log *logrus.Logger) (*OSCommand, error) {
osCommand := &OSCommand{
func NewOSCommand(log *logrus.Logger) *OSCommand {
return &OSCommand{
Log: log,
Platform: getPlatform(),
}
return osCommand, nil
}
// RunCommandWithOutput wrapper around commands returning their output and error