Skip to content

Commit

Permalink
Fix lint errors and update the linter to revive.
Browse files Browse the repository at this point in the history
golint is deprecated and archived, so golangci-lint recommends updating
to revive. This handles the update and fixes new lint errors.

Signed-off-by: Dan Lorenc <dlorenc@google.com>
  • Loading branch information
Dan Lorenc authored and tekton-robot committed Sep 1, 2021
1 parent ad220f8 commit b36e824
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ linters:
- goimports
- gosec
- gocritic
- golint
- revive
3 changes: 1 addition & 2 deletions pkg/reconciler/eventlistener/eventlistener.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,7 @@ func (r *Reconciler) ReconcileKind(ctx context.Context, el *v1beta1.EventListene
el.SetDefaults(contexts.WithUpgradeViaDefaulting(ctx))

if el.Spec.Resources.CustomResource != nil {
kError := r.reconcileCustomObject(ctx, el)
return wrapError(kError, nil)
return r.reconcileCustomObject(ctx, el)
}
deploymentReconcileError := r.reconcileDeployment(ctx, el)
serviceReconcileError := r.reconcileService(ctx, el)
Expand Down
2 changes: 1 addition & 1 deletion test/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ func init() {
}

// SeedResources returns Clients populated with the given Resources
// nolint: golint
// nolint: revive
func SeedResources(t *testing.T, ctx context.Context, r Resources) Clients {
t.Helper()
c := Clients{
Expand Down

0 comments on commit b36e824

Please sign in to comment.