From 4b58775f640de61125e00ef81482d8ace665191a Mon Sep 17 00:00:00 2001 From: Alexander Peters Date: Sun, 2 Jun 2024 23:23:11 +0200 Subject: [PATCH] Typos and minor fixes (#3429) Signed-off-by: Alex Peters Signed-off-by: Dan Sun Co-authored-by: Dan Sun --- pkg/controller/v1beta1/inferenceservice/controller.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkg/controller/v1beta1/inferenceservice/controller.go b/pkg/controller/v1beta1/inferenceservice/controller.go index 805d3399845..5086387cc3d 100644 --- a/pkg/controller/v1beta1/inferenceservice/controller.go +++ b/pkg/controller/v1beta1/inferenceservice/controller.go @@ -76,7 +76,7 @@ import ( // +kubebuilder:rbac:groups=core,resources=events,verbs=get;list;watch;create;update;patch;delete // +kubebuilder:rbac:groups=core,resources=pods,verbs=get;list;watch -// InferenceState describes the Readiness of the InferenceService +// InferenceServiceState describes the Readiness of the InferenceService type InferenceServiceState string // Different InferenceServiceState an InferenceService may have. @@ -96,8 +96,6 @@ type InferenceServiceReconciler struct { } func (r *InferenceServiceReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { - _ = context.Background() - // Fetch the InferenceService instance isvc := &v1beta1api.InferenceService{} if err := r.Get(ctx, req.NamespacedName, isvc); err != nil { @@ -261,7 +259,7 @@ func (r *InferenceServiceReconciler) Reconcile(ctx context.Context, req ctrl.Req } if err = r.updateStatus(isvc, deploymentMode); err != nil { - r.Recorder.Eventf(isvc, v1.EventTypeWarning, "InternalError", err.Error()) + r.Recorder.Event(isvc, v1.EventTypeWarning, "InternalError", err.Error()) return reconcile.Result{}, err }