improve comment multiline matching

This commit is contained in:
dre 2021-07-11 13:48:26 +08:00
parent 563b714ed6
commit 8bfd57bef1

View file

@ -11,7 +11,7 @@ func RemoveComments(in chan pipe.StreamItem) chan pipe.StreamItem {
out := make(chan pipe.StreamItem)
go func() {
re := regexp.MustCompile(`<!--.*-->`)
re := regexp.MustCompile(`(?s)<!--(.*?)-->`)
for b := range in {
data := b.Payload()