From bfe45eef34bfad73dc9c5255ac8f06ae19501554 Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Sun, 21 Jul 2019 06:15:34 +0200 Subject: plumbing/format: simplify code Just a bit easier to read, in my opinion. Signed-off-by: Christian Muehlhaeuser (cherry picked from commit 91d314ce8f13eff06fd4af8b869cee5a3e2ab014) --- plumbing/format/diff/unified_encoder.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'plumbing/format/diff') diff --git a/plumbing/format/diff/unified_encoder.go b/plumbing/format/diff/unified_encoder.go index 8bd6d8a..169242d 100644 --- a/plumbing/format/diff/unified_encoder.go +++ b/plumbing/format/diff/unified_encoder.go @@ -94,7 +94,7 @@ func (e *UnifiedEncoder) printMessage(message string) { isEmpty := message == "" hasSuffix := strings.HasSuffix(message, "\n") if !isEmpty && !hasSuffix { - message = message + "\n" + message += "\n" } e.buf.WriteString(message) -- cgit