Skip to content

Commit

Permalink
Merge pull request #993 from ArthurSens/fix-992
Browse files Browse the repository at this point in the history
  • Loading branch information
metalmatze authored Dec 6, 2023
2 parents 875ff1d + 7cf76ea commit 83b0b8b
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions kubernetes/controllers/servicelevelobjective.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,9 @@ func (r *ServiceLevelObjectiveReconciler) reconcilePrometheusRule(ctx context.Co
if err := r.Create(ctx, newRule); err != nil {
return ctrl.Result{}, err
}
return ctrl.Result{}, fmt.Errorf("failed to create prometheus rule: %w", err)
} else {
return ctrl.Result{}, fmt.Errorf("failed to get prometheus rule: %w", err)
}

return ctrl.Result{}, fmt.Errorf("failed to get prometheus rule: %w", err)
}

newRule.ResourceVersion = rule.ResourceVersion
Expand Down Expand Up @@ -123,9 +122,9 @@ func (r *ServiceLevelObjectiveReconciler) reconcileConfigMap(
if err := r.Create(ctx, newConfigMap); err != nil {
return ctrl.Result{}, fmt.Errorf("failed to create config map: %w", err)
}
} else {
return ctrl.Result{}, fmt.Errorf("failed to get config map: %w", err)
}

return ctrl.Result{}, err
}

newConfigMap.ResourceVersion = existingConfigMap.ResourceVersion
Expand Down

0 comments on commit 83b0b8b

Please sign in to comment.