Skip to content

Commit 4b4dfa5

Browse files
committed
Ran golangci-lint linter to fix lint errors
1 parent 018d717 commit 4b4dfa5

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

internal/metric/disk.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ func CollectDiskMetrics() (MetricsSlice, []CustomErr) {
218218
defaultDiskData := []*DiskData{
219219
{
220220
Device: "unknown",
221-
Mountpoint: "unknown",
221+
Mountpoint: "unknown",
222222
TotalBytes: nil,
223223
FreeBytes: nil,
224224
UsedBytes: nil,

internal/metric/metric.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ func (m MemoryData) isMetric() {}
6565

6666
type DiskData struct {
6767
Device string `json:"device"` // Device
68-
Mountpoint string `json:"mountpoint"` // Mountpoint
68+
Mountpoint string `json:"mountpoint"` // Mountpoint
6969
TotalBytes *uint64 `json:"total_bytes"` // Total space of device in bytes
7070
FreeBytes *uint64 `json:"free_bytes"` // Free space of device in bytes
7171
UsedBytes *uint64 `json:"used_bytes"` // Used space of device in bytes

test/integration/disk_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ func TestDiskMetricsContent(t *testing.T) {
4848
t.Errorf("Disk device %s has an empty Mountpoint field", diskData.Device)
4949
} else if diskData.Mountpoint == "unknown" {
5050
t.Logf("Disk device %s has default 'unknown' mountpoint (metric collection may have failed)", diskData.Device)
51-
} else {
51+
} else {
5252
foundValidDisk = true
5353
}
5454
}
@@ -57,4 +57,4 @@ func TestDiskMetricsContent(t *testing.T) {
5757
if !foundValidDisk {
5858
t.Error("No valid disks with mountpoints were found. The mountpoint feature may not be working correctly.")
5959
}
60-
}
60+
}

0 commit comments

Comments
 (0)