Skip to content

Commit

Permalink
minor cleanup
Browse files Browse the repository at this point in the history
Signed-off-by: Arik Hadas <[email protected]>
  • Loading branch information
ahadas committed Dec 24, 2023
1 parent 024f339 commit 52eb741
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 9 deletions.
10 changes: 2 additions & 8 deletions pkg/controller/provider/ova-setup.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,10 +91,7 @@ func (r *Reconciler) createPvForNfs(provider *api.Provider, ctx context.Context,
},
}
err = r.Create(ctx, pv)
if err != nil {
return
}
return pv, nil
return
}

func (r *Reconciler) createPvcForNfs(provider *api.Provider, ctx context.Context, ownerReference metav1.OwnerReference, pvName, pvcNamePrefix string) (pvc *core.PersistentVolumeClaim, err error) {
Expand All @@ -121,10 +118,7 @@ func (r *Reconciler) createPvcForNfs(provider *api.Provider, ctx context.Context
},
}
err = r.Create(ctx, pvc)
if err != nil {
return
}
return pvc, nil
return
}

func (r *Reconciler) createServerDeployment(provider *api.Provider, ctx context.Context, ownerReference metav1.OwnerReference, pvcName string, labels map[string]string) (err error) {
Expand Down
2 changes: 1 addition & 1 deletion pkg/controller/provider/validation.go
Original file line number Diff line number Diff line change
Expand Up @@ -362,7 +362,7 @@ func (r *Reconciler) inventoryCreated(provider *api.Provider) error {

func (r *Reconciler) handleServerCreationFailure(provider *api.Provider, err error) {
provider.Status.Phase = ConnectionAuthFailed
msg := fmt.Sprint("The OVA provider server creation failed:", err)
msg := fmt.Sprint("The OVA provider server creation failed: ", err)
provider.Status.SetCondition(
libcnd.Condition{
Type: ConnectionAuthFailed,
Expand Down

0 comments on commit 52eb741

Please sign in to comment.