diff options
author | Anthony HAMON <anthony.hamon@iadvize.com> | 2018-08-21 21:09:53 +0200 |
---|---|---|
committer | Anthony HAMON <anthony.hamon@iadvize.com> | 2018-08-26 01:58:19 +0200 |
commit | a5adfaee8ab29afd7aab434a3cf0a9d7e41f8879 (patch) | |
tree | 9982b1f681bcc408f3c9ea04694565d4b3878c6a /pkg | |
parent | 93ab892bdd1226f9a519a938c8b28590e71e54f3 (diff) |
remove useless returned variable
Diffstat (limited to 'pkg')
-rw-r--r-- | pkg/app/app.go | 5 | ||||
-rw-r--r-- | pkg/commands/os.go | 5 |
2 files changed, 3 insertions, 7 deletions
diff --git a/pkg/app/app.go b/pkg/app/app.go index 102ab4146..6b3a37ef0 100644 --- a/pkg/app/app.go +++ b/pkg/app/app.go @@ -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) diff --git a/pkg/commands/os.go b/pkg/commands/os.go index 1eef36151..9ccd10eb6 100644 --- a/pkg/commands/os.go +++ b/pkg/commands/os.go @@ -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 |