From e8297c491f49e8602398f593b4df86a836a0a285 Mon Sep 17 00:00:00 2001 From: Ismael Padilla Date: Thu, 14 Jul 2022 17:17:36 -0300 Subject: [PATCH] Use ReplaceAll instead of Replace with n=-1 --- style.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/style.go b/style.go index edf3126..576ace4 100644 --- a/style.go +++ b/style.go @@ -262,7 +262,7 @@ func (s Style) Render(str string) string { // Strip newlines in single line mode if inline { - str = strings.Replace(str, "\n", "", -1) + str = strings.ReplaceAll(str, "\n", "") } // Word wrap