mirror of
https://github.com/superseriousbusiness/gotosocial
synced 2025-06-05 21:59:39 +02:00
[chore]: Bump github.com/tdewolff/minify/v2 from 2.20.9 to 2.20.12 (#2509)
Bumps [github.com/tdewolff/minify/v2](https://github.com/tdewolff/minify) from 2.20.9 to 2.20.12. - [Release notes](https://github.com/tdewolff/minify/releases) - [Commits](https://github.com/tdewolff/minify/compare/v2.20.9...v2.20.12) --- updated-dependencies: - dependency-name: github.com/tdewolff/minify/v2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This commit is contained in:
22
vendor/github.com/tdewolff/parse/v2/html/lex.go
generated
vendored
22
vendor/github.com/tdewolff/parse/v2/html/lex.go
generated
vendored
@ -166,6 +166,7 @@ func (l *Lexer) Next() (TokenType, []byte) {
|
||||
isEndTag := c == '/' && l.r.Peek(2) != '>' && (l.r.Peek(2) != 0 || l.r.PeekErr(2) == nil)
|
||||
if !isEndTag && (c < 'a' || 'z' < c) && (c < 'A' || 'Z' < c) && c != '!' && c != '?' {
|
||||
// not a tag
|
||||
l.r.Move(1)
|
||||
} else if 0 < l.r.Pos() {
|
||||
// return currently buffered texttoken so that we can return tag next iteration
|
||||
l.text = l.r.Shift()
|
||||
@ -202,8 +203,9 @@ func (l *Lexer) Next() (TokenType, []byte) {
|
||||
return TextToken, l.text
|
||||
}
|
||||
return ErrorToken, nil
|
||||
} else {
|
||||
l.r.Move(1)
|
||||
}
|
||||
l.r.Move(1)
|
||||
}
|
||||
}
|
||||
|
||||
@ -539,19 +541,19 @@ func (l *Lexer) shiftXML(rawTag Hash) []byte {
|
||||
|
||||
func (l *Lexer) moveTemplate() {
|
||||
for {
|
||||
if c := l.r.Peek(0); l.at(l.tmplEnd...) || c == 0 && l.r.Err() != nil {
|
||||
if c != 0 {
|
||||
l.r.Move(len(l.tmplEnd))
|
||||
}
|
||||
break
|
||||
if c := l.r.Peek(0); c == 0 && l.r.Err() != nil {
|
||||
return
|
||||
} else if l.at(l.tmplEnd...) {
|
||||
l.r.Move(len(l.tmplEnd))
|
||||
return
|
||||
} else if c == '"' || c == '\'' {
|
||||
l.r.Move(1)
|
||||
escape := false
|
||||
for {
|
||||
if c2 := l.r.Peek(0); !escape && c2 == c || c2 == 0 && l.r.Err() != nil {
|
||||
if c2 != 0 {
|
||||
l.r.Move(1)
|
||||
}
|
||||
if c2 := l.r.Peek(0); c2 == 0 && l.r.Err() != nil {
|
||||
return
|
||||
} else if !escape && c2 == c {
|
||||
l.r.Move(1)
|
||||
break
|
||||
} else if c2 == '\\' {
|
||||
escape = !escape
|
||||
|
Reference in New Issue
Block a user