soup
soup copied to clipboard
findOnce break after the first child node.
If the element is not found in the first child node, the value is returned, and the loop has no effect.
I think this should be if q {
for c := n.FirstChild; c != nil; c = c.NextSibling {
p, q := findOnce(c, args, true, strict)
if !q {
return p, q
}
}
https://github.com/anaskhan96/soup/blob/cb47551b378185a4504cf253c2abfbeea361cabf/soup.go#L504