Skip to content

Commit

Permalink
Dup fix
Browse files Browse the repository at this point in the history
  • Loading branch information
chetan-spheron committed Nov 11, 2024
1 parent 5a03e73 commit d5078b4
Showing 1 changed file with 13 additions and 11 deletions.
24 changes: 13 additions & 11 deletions go/inventory/v1/gpu.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,13 @@ func (r *GPU) Dup() GPU {

func (s *GPUInfo) Dup() GPUInfo {
res := GPUInfo{
Vendor: s.Vendor,
VendorID: s.VendorID,
Name: s.Name,
ModelID: s.ModelID,
Interface: s.Interface,
MemorySize: s.MemorySize,
Vendor: s.Vendor,
VendorID: s.VendorID,
Name: s.Name,
ModelID: s.ModelID,
Interface: s.Interface,
MemorySize: s.MemorySize,
VRAMAvailablePercentage: s.VRAMAvailablePercentage,
}

return res
Expand All @@ -45,11 +46,12 @@ func (s GPUInfoS) Dup() GPUInfoS {

for _, n := range s {
res = append(res, GPUInfo{
Vendor: n.Vendor,
Name: n.Name,
ModelID: n.ModelID,
Interface: n.Interface,
MemorySize: n.MemorySize,
Vendor: n.Vendor,
Name: n.Name,
ModelID: n.ModelID,
Interface: n.Interface,
MemorySize: n.MemorySize,
VRAMAvailablePercentage: n.VRAMAvailablePercentage,
})
}

Expand Down

0 comments on commit d5078b4

Please sign in to comment.