cli/charger: hide empty features

This commit is contained in:
andig 2024-07-01 10:15:20 +02:00
parent c9453c2bc0
commit 2d72a29fc8

View file

@ -233,8 +233,9 @@ func (d *dumper) Dump(name string, v interface{}) {
// features
if v, ok := v.(api.FeatureDescriber); ok {
ff := v.Features()
fmt.Fprintf(w, "Features:\t%v\n", ff)
if ff := v.Features(); len(ff) > 0 {
fmt.Fprintf(w, "Features:\t%v\n", ff)
}
}
w.Flush()