mirror of
https://github.com/kubernetes-sigs/node-feature-discovery.git
synced 2025-03-05 08:17:04 +00:00
utils/dump: do not print empty header line
Makes log output cleaner.
This commit is contained in:
parent
aa2cbad3a9
commit
99d223b029
1 changed files with 3 additions and 1 deletions
|
@ -26,7 +26,9 @@ import (
|
|||
|
||||
func KlogDump(v klog.Level, heading, prefix string, obj interface{}) {
|
||||
if klog.V(v).Enabled() {
|
||||
klog.InfoDepth(1, heading)
|
||||
if heading != "" {
|
||||
klog.InfoDepth(1, heading)
|
||||
}
|
||||
|
||||
d := strings.Split(Dump(obj), "\n")
|
||||
// Print all but the last empty line
|
||||
|
|
Loading…
Add table
Reference in a new issue