use log for error instead of fmt

This commit is contained in:
rare-magma 2022-06-07 20:43:04 +02:00
parent 98c69b7dac
commit 6a979718dc

View File

@ -4,7 +4,6 @@
package devices
import (
"fmt"
"log"
smart "github.com/anatol/smart.go"
@ -43,7 +42,7 @@ func getTemps(temps map[string]int) map[string]error {
for _, disk := range block.Disks {
dev, err := smart.Open("/dev/" + disk.Name)
if err != nil {
fmt.Println(err)
log.Println(err)
continue
}
switch sm := dev.(type) {