changed error to only return

This commit is contained in:
Mehmet Soysal 2022-03-04 12:39:35 +01:00
parent 40915c16ef
commit 4c5a915f74
No known key found for this signature in database
GPG Key ID: 7B6342DE1987F322
2 changed files with 2 additions and 4 deletions

View File

@ -4,7 +4,6 @@ import (
"bufio" "bufio"
"bytes" "bytes"
"encoding/json" "encoding/json"
"errors"
"fmt" "fmt"
"io/ioutil" "io/ioutil"
"os" "os"
@ -131,7 +130,7 @@ func (m *BeegfsMetaCollector) Read(interval time.Duration, output chan lp.CCMetr
} }
if len(mountpoints) == 0 { if len(mountpoints) == 0 {
return errors.New("Could not find any BeeGFS mountpoint") return
} }
for _, mountpoint := range mountpoints { for _, mountpoint := range mountpoints {

View File

@ -4,7 +4,6 @@ import (
"bufio" "bufio"
"bytes" "bytes"
"encoding/json" "encoding/json"
"errors"
"fmt" "fmt"
"io/ioutil" "io/ioutil"
"os" "os"
@ -125,7 +124,7 @@ func (m *BeegfsStorageCollector) Read(interval time.Duration, output chan lp.CCM
} }
} }
if len(mountpoints) == 0 { if len(mountpoints) == 0 {
return errors.New("Could not find any BeeGFS mountpoint") return
} }
// collects stats for each BeeGFS on Demand FS // collects stats for each BeeGFS on Demand FS
for _, mountpoint := range mountpoints { for _, mountpoint := range mountpoints {