netdata/netdata

View on GitHub
src/go/collectors/go.d.plugin/modules/litespeed/collect.go

Summary

Maintainability
A
1 hr
Test Coverage

Method Litespeed.collectReport has 58 lines of code (exceeds 50 allowed). Consider refactoring.
Open

func (l *Litespeed) collectReport(mx map[string]int64, filename string) error {
    bs, err := os.ReadFile(filename)
    if err != nil {
        return err
    }
Severity: Minor
Found in src/go/collectors/go.d.plugin/modules/litespeed/collect.go - About 1 hr to fix

    Method Litespeed.collect has 5 return statements (exceeds 4 allowed).
    Open

    func (l *Litespeed) collect() (map[string]int64, error) {
        if l.checkDir {
            _, err := os.Stat(l.ReportsDir)
            if err != nil {
                return nil, err
    Severity: Major
    Found in src/go/collectors/go.d.plugin/modules/litespeed/collect.go - About 35 mins to fix

      There are no issues that match your filters.

      Category
      Status