Set omitempty for disk capacity json

This commit is contained in:
Alan Bernstein 2020-10-09 09:27:48 -05:00 committed by Jason E. Aten
parent ba4ca1a93e
commit 6a298590be

2
api.go
View file

@ -801,7 +801,7 @@ type NodeUsage struct {
// DiskUsage represents the storage space used on disk by one node.
type DiskUsage struct {
Capacity uint64 `json:"capacity"`
Capacity uint64 `json:"capacity,omitempty"`
TotalUse int64 `json:"totalInUse"`
Indexes map[string]int64 `json:"indexes"`
}