diff --git a/internal/util/parse.go b/internal/util/parse.go index 3f1b174a0..22cb07a6b 100644 --- a/internal/util/parse.go +++ b/internal/util/parse.go @@ -74,7 +74,7 @@ func ReadUintFromFile(path string) (uint64, error) { } // ReadIntFromFile reads a file and attempts to parse a int64 from it. -func ReadIntFromFromFile(path string) (int64, error) { +func ReadIntFromFile(path string) (int64, error) { data, err := ioutil.ReadFile(path) if err != nil { return 0, err diff --git a/sysfs/class_thermal.go b/sysfs/class_thermal.go index c20639f20..457c6bda2 100644 --- a/sysfs/class_thermal.go +++ b/sysfs/class_thermal.go @@ -67,7 +67,7 @@ func parseClassThermalZone(zone string) (ClassThermalZoneStats, error) { if err != nil { return ClassThermalZoneStats{}, err } - zoneTemp, err := util.ReadIntFromFromFile(filepath.Join(zone, "temp")) + zoneTemp, err := util.ReadIntFromFile(filepath.Join(zone, "temp")) if err != nil { return ClassThermalZoneStats{}, err }