mirror of
https://git.vectorsigma.ru/public/atlantis.git
synced 2026-07-29 01:28:44 +00:00
check if err is nil before printing it
This commit is contained in:
@@ -18,7 +18,9 @@ func (b *BootstrapCmd) Init() *cobra.Command {
|
||||
Short: "Start a guided tour of Atlantis",
|
||||
RunE: func(cmd *cobra.Command, args []string) error {
|
||||
err := bootstrap.Start()
|
||||
fmt.Fprintf(os.Stderr, "\033[31mError: %s\033[39m\n\n", err.Error())
|
||||
if err != nil {
|
||||
fmt.Fprintf(os.Stderr, "\033[31mError: %s\033[39m\n\n", err.Error())
|
||||
}
|
||||
return err
|
||||
},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user