mirror of
https://github.com/containers/podman.git
synced 2025-06-21 17:38:12 +08:00
Fix missing headers in network ls
Signed-off-by: Jhon Honce <jhonce@redhat.com>
This commit is contained in:
@ -87,8 +87,11 @@ func networkList(cmd *cobra.Command, args []string) error {
|
|||||||
nlprs = append(nlprs, ListPrintReports{r})
|
nlprs = append(nlprs, ListPrintReports{r})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Headers() gets lost resolving the embedded field names so add them
|
||||||
headers := report.Headers(ListPrintReports{}, map[string]string{
|
headers := report.Headers(ListPrintReports{}, map[string]string{
|
||||||
|
"Name": "name",
|
||||||
"CNIVersion": "version",
|
"CNIVersion": "version",
|
||||||
|
"Version": "version",
|
||||||
"Plugins": "plugins",
|
"Plugins": "plugins",
|
||||||
})
|
})
|
||||||
renderHeaders := true
|
renderHeaders := true
|
||||||
@ -110,7 +113,6 @@ func networkList(cmd *cobra.Command, args []string) error {
|
|||||||
if err := tmpl.Execute(w, headers); err != nil {
|
if err := tmpl.Execute(w, headers); err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
return tmpl.Execute(w, nlprs)
|
return tmpl.Execute(w, nlprs)
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user