Skip to content

Commit

Permalink
Use ReplaceAll instead of Replace with n=-1
Browse files Browse the repository at this point in the history
  • Loading branch information
ismaelpadilla authored and muesli committed Jul 14, 2022
1 parent a86f21a commit e8297c4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion style.go
Expand Up @@ -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
Expand Down

0 comments on commit e8297c4

Please sign in to comment.