Skip to content

Commit

Permalink
Fix the error might be overwrited issue
Browse files Browse the repository at this point in the history
  • Loading branch information
LinuxSuRen committed Nov 24, 2021
1 parent 03c2bcb commit 051f862
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion kubectl-plugin/config/migrate.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,11 @@ func (o *migrateOption) runE(cmd *cobra.Command, args []string) (err error) {

var password string
if password, err = o.getDevOpsPassword(); password == "" {
err = fmt.Errorf("the password of Jenkins is empty")
if err == nil {
err = fmt.Errorf("the password of Jenkins is empty")
} else {
err = fmt.Errorf("the password of Jenkins is empty, it might caused by: %v", err)
}
} else if err == nil {
err = o.updateKubeSphereConfig("devops-config", o.namespace, map[string]interface{}{
"password": password,
Expand Down

0 comments on commit 051f862

Please sign in to comment.