Skip to content

Commit

Permalink
fixed gohugoio#7958 Trim all whitespace in elements written to hugo_s…
Browse files Browse the repository at this point in the history
…tats.json
pmatiash committed Jan 27, 2021

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
1 parent ed3071b commit 7aad618
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions publisher/htmlElementsCollector.go
Original file line number Diff line number Diff line change
@@ -149,6 +149,7 @@ func (c *cssClassCollectorWriter) insertStandinHTMLElement(el string) (string, s
if spacei != -1 {
tag = tag[:spacei]
}
tag = strings.Trim(tag, "\n ")
newv := strings.Replace(el, tag, "div", 1)
return newv, strings.ToLower(tag)
}

0 comments on commit 7aad618

Please sign in to comment.