ref(kube): Gets rid of superfluous Sprintf call

Signed-off-by: Taylor Thomas <thomastaylor312@gmail.com>
pull/5019/head
Taylor Thomas 6 years ago
parent 88af9659a2
commit 6d3809a416

@ -220,8 +220,7 @@ func (c *Client) Get(namespace string, reader io.Reader) (string, error) {
buf := new(bytes.Buffer) buf := new(bytes.Buffer)
printFlags := get.NewHumanPrintFlags() printFlags := get.NewHumanPrintFlags()
for t, ot := range objs { for t, ot := range objs {
kindHeader := fmt.Sprintf("==> %s\n", t) if _, err = fmt.Fprintf(buf, "==> %s\n", t); err != nil {
if _, err = buf.WriteString(kindHeader); err != nil {
return "", err return "", err
} }
typePrinter, _ := printFlags.ToPrinter("") typePrinter, _ := printFlags.ToPrinter("")

Loading…
Cancel
Save