Skip to content

Commit 0994930

Browse files
committed
fix: linter errors
Signed-off-by: fullykubed <[email protected]>
1 parent 000d3f1 commit 0994930

File tree

2 files changed

+22
-22
lines changed

2 files changed

+22
-22
lines changed

pkg/reconciler/cmd/start.go

+20-20
Original file line numberDiff line numberDiff line change
@@ -163,26 +163,26 @@ func Start(eventsOpts ArgoEventsControllerOpts) {
163163
// by the EventSource. This controller provides the EventBus config via an env var which is why we need
164164
// to reconcile the EventSource when the EventBus status.config updates.
165165
if err := eventSourceController.Watch(
166-
source.Kind(mgr.GetCache(), &aev1.EventBus{},
167-
handler.TypedEnqueueRequestsFromMapFunc[*aev1.EventBus](func(ctx context.Context, eventBus *aev1.EventBus) []reconcile.Request {
168-
var eventSourceList aev1.EventSourceList
169-
if err := mgr.GetClient().List(ctx, &eventSourceList, client.InNamespace(eventBus.Namespace)); err != nil {
170-
logger.Errorw("Failed to list EventSources", zap.Error(err))
171-
return nil
172-
}
173-
var requests []reconcile.Request
174-
for _, es := range eventSourceList.Items {
175-
requests = append(requests, reconcile.Request{
176-
NamespacedName: types.NamespacedName{
177-
Name: es.Name,
178-
Namespace: es.Namespace,
179-
},
180-
})
181-
}
182-
return requests
183-
}),
184-
common.EventBusConfigStatusChangedPredicate{},
185-
)); err != nil {
166+
source.Kind(mgr.GetCache(), &aev1.EventBus{},
167+
handler.TypedEnqueueRequestsFromMapFunc[*aev1.EventBus](func(ctx context.Context, eventBus *aev1.EventBus) []reconcile.Request {
168+
var eventSourceList aev1.EventSourceList
169+
if err := mgr.GetClient().List(ctx, &eventSourceList, client.InNamespace(eventBus.Namespace)); err != nil {
170+
logger.Errorw("Failed to list EventSources", zap.Error(err))
171+
return nil
172+
}
173+
var requests []reconcile.Request
174+
for _, es := range eventSourceList.Items {
175+
requests = append(requests, reconcile.Request{
176+
NamespacedName: types.NamespacedName{
177+
Name: es.Name,
178+
Namespace: es.Namespace,
179+
},
180+
})
181+
}
182+
return requests
183+
}),
184+
common.EventBusConfigStatusChangedPredicate{},
185+
)); err != nil {
186186
logger.Fatalw("Unable to watch EventBus for EventSource updates", zap.Error(err))
187187
}
188188

pkg/reconciler/eventsource/resource.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -171,12 +171,12 @@ func getDeployment(ctx context.Context, cl client.Client, args *AdaptorArgs) (*a
171171
return nil, apierrors.NewNotFound(schema.GroupResource{}, "")
172172
}
173173

174-
func buildDeployment(args *AdaptorArgs, eventBus *aev1.EventBus) (*appv1.Deployment, error) {
174+
func buildDeployment(args *AdaptorArgs, eventBus *v1alpha1.EventBus) (*appv1.Deployment, error) {
175175
deploymentSpec, err := buildDeploymentSpec(args)
176176
if err != nil {
177177
return nil, err
178178
}
179-
eventSourceCopy := &aev1.EventSource{
179+
eventSourceCopy := &v1alpha1.EventSource{
180180
ObjectMeta: metav1.ObjectMeta{
181181
Namespace: args.EventSource.Namespace,
182182
Name: args.EventSource.Name,

0 commit comments

Comments
 (0)