Skip to content

Commit

Permalink
Fix error check.
Browse files Browse the repository at this point in the history
  • Loading branch information
Miles-Garnsey committed Dec 11, 2023
1 parent e43825d commit 95975df
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion controllers/medusa/medusarestorejob_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,13 @@ func (r *MedusaRestoreJobReconciler) Reconcile(ctx context.Context, req ctrl.Req
}

request.Log.Info("The restore operation is complete")
medusa.RefreshSecrets(request.Datacenter, ctx, r.Client, request.Log, r.DefaultDelay)

err = medusa.RefreshSecrets(request.Datacenter, ctx, r.Client, request.Log, r.DefaultDelay)
if err != nil {
request.Log.Error(err, "Failed to refresh Cassandra users in the DB")
// Not going to bother applying updates here since we hit an error.
return ctrl.Result{RequeueAfter: r.DefaultDelay}, err
}

return ctrl.Result{}, nil
}
Expand Down

0 comments on commit 95975df

Please sign in to comment.