Skip to content

Commit b8dbbb0

Browse files
committed
refactor: refactor disk info
1 parent 86101b9 commit b8dbbb0

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

pkg/status/status.go

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,10 +48,7 @@ func Disk(INTERVAL *float64) (uint64, uint64) {
4848
diskList, _ := disk.Partitions(false)
4949
devices := make(map[string]bool)
5050
for _, d := range diskList {
51-
if checkValidFs(d.Fstype) {
52-
if devices[d.Device] {
53-
continue
54-
}
51+
if !devices[d.Device] && checkValidFs(d.Fstype) {
5552
cachedFs[d.Mountpoint] = struct{}{}
5653
devices[d.Device] = true
5754
}

0 commit comments

Comments
 (0)