Skip to content

Commit

Permalink
rhel: lints
Browse files Browse the repository at this point in the history
Signed-off-by: Hank Donnay <[email protected]>
  • Loading branch information
hdonnay committed Jan 12, 2024
1 parent 7db3fbe commit 6c4f1b5
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
10 changes: 5 additions & 5 deletions rhel/ecosystem.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,18 @@ import (
)

// NewEcosystem provides the set of scanners and coalescer for the rhel ecosystem.
func NewEcosystem(ctx context.Context) *indexer.Ecosystem {
func NewEcosystem(_ context.Context) *indexer.Ecosystem {

Check warning on line 11 in rhel/ecosystem.go

View check run for this annotation

Codecov / codecov/patch

rhel/ecosystem.go#L11

Added line #L11 was not covered by tests
return &indexer.Ecosystem{
PackageScanners: func(ctx context.Context) ([]indexer.PackageScanner, error) {
PackageScanners: func(_ context.Context) ([]indexer.PackageScanner, error) {

Check warning on line 13 in rhel/ecosystem.go

View check run for this annotation

Codecov / codecov/patch

rhel/ecosystem.go#L13

Added line #L13 was not covered by tests
return []indexer.PackageScanner{new(rpm.Scanner)}, nil
},
DistributionScanners: func(ctx context.Context) ([]indexer.DistributionScanner, error) {
DistributionScanners: func(_ context.Context) ([]indexer.DistributionScanner, error) {

Check warning on line 16 in rhel/ecosystem.go

View check run for this annotation

Codecov / codecov/patch

rhel/ecosystem.go#L16

Added line #L16 was not covered by tests
return []indexer.DistributionScanner{new(DistributionScanner)}, nil
},
RepositoryScanners: func(ctx context.Context) ([]indexer.RepositoryScanner, error) {
RepositoryScanners: func(_ context.Context) ([]indexer.RepositoryScanner, error) {

Check warning on line 19 in rhel/ecosystem.go

View check run for this annotation

Codecov / codecov/patch

rhel/ecosystem.go#L19

Added line #L19 was not covered by tests
return []indexer.RepositoryScanner{new(RepositoryScanner)}, nil
},
Coalescer: func(ctx context.Context) (indexer.Coalescer, error) {
Coalescer: func(_ context.Context) (indexer.Coalescer, error) {

Check warning on line 22 in rhel/ecosystem.go

View check run for this annotation

Codecov / codecov/patch

rhel/ecosystem.go#L22

Added line #L22 was not covered by tests
return new(Coalescer), nil
},
}
Expand Down
2 changes: 1 addition & 1 deletion rhel/matcher.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ func (*Matcher) Query() []driver.MatchConstraint {
}

// Vulnerable implements driver.Matcher.
func (m *Matcher) Vulnerable(ctx context.Context, record *claircore.IndexRecord, vuln *claircore.Vulnerability) (bool, error) {
func (m *Matcher) Vulnerable(_ context.Context, record *claircore.IndexRecord, vuln *claircore.Vulnerability) (bool, error) {
pkgVer := version.NewVersion(record.Package.Version)
var vulnVer version.Version
// Assume the vulnerability record we have is for the last known vulnerable
Expand Down
2 changes: 1 addition & 1 deletion rhel/updaterset.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const DefaultManifest = `https://access.redhat.com/security/data/oval/v2/PULP_MA

// NewFactory creates a Factory making updaters based on the contents of the
// provided pulp manifest.
func NewFactory(ctx context.Context, manifest string) (*Factory, error) {
func NewFactory(_ context.Context, manifest string) (*Factory, error) {

Check warning on line 25 in rhel/updaterset.go

View check run for this annotation

Codecov / codecov/patch

rhel/updaterset.go#L25

Added line #L25 was not covered by tests
var err error
var f Factory
f.url, err = url.Parse(manifest)
Expand Down

0 comments on commit 6c4f1b5

Please sign in to comment.