Skip to content

Commit

Permalink
chore: revive lint with unused context params
Browse files Browse the repository at this point in the history
  • Loading branch information
tbelda-ems committed Nov 19, 2023
1 parent f6af098 commit 778473a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion internal/ovirtcollector/api_summary.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (

// CollectAPISummaryInfo gathers oVirt api's summary info
func (c *OVirtCollector) CollectAPISummaryInfo(
ctx context.Context,
_ context.Context,
acc *metric.Accumulator,
) error {
var (
Expand Down
4 changes: 2 additions & 2 deletions internal/ovirtcollector/cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ type VcCache struct {
lastVMUpdate time.Time
}

func (c *OVirtCollector) getDatacentersAndClusters(ctx context.Context) error {
func (c *OVirtCollector) getDatacentersAndClusters(_ context.Context) error {
if time.Since(c.lastDCUpdate) < c.dataDuration {
return nil
}
Expand Down Expand Up @@ -121,7 +121,7 @@ func (c *OVirtCollector) getAllDatacentersVMs(ctx context.Context) error {
return err
}

// Get all VMs
// Get all VMs
vmsService := c.conn.SystemService().VmsService()
vmsResponse, err := vmsService.List().Send()
if err != nil {
Expand Down
4 changes: 2 additions & 2 deletions internal/ovirtcollector/ovirtcollector.go
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ func (c *OVirtCollector) SetFilterVms(include, exclude []string) error {
}

// Open opens a OVirt connection session
func (c *OVirtCollector) Open(ctx context.Context, timeout time.Duration) error {
func (c *OVirtCollector) Open(_ context.Context, timeout time.Duration) error {
var err error

c.conn, err = ovirtsdk.NewConnectionBuilder().
Expand All @@ -131,7 +131,7 @@ func (c *OVirtCollector) Open(ctx context.Context, timeout time.Duration) error
}

// IsActive let us know if the OVirt connection is active or not
func (c *OVirtCollector) IsActive(ctx context.Context) bool {
func (c *OVirtCollector) IsActive(_ context.Context) bool {
if c.conn != nil && c.conn.Test() == nil {
return true
}
Expand Down

0 comments on commit 778473a

Please sign in to comment.