Checks if the target node is in the slice of nodes.
(slice []*html.Node, node *html.Node)
| 108 | |
| 109 | // Checks if the target node is in the slice of nodes. |
| 110 | func isInSlice(slice []*html.Node, node *html.Node) bool { |
| 111 | return indexInSlice(slice, node) > -1 |
| 112 | } |
| 113 | |
| 114 | // Returns the index of the target node in the slice, or -1. |
| 115 | func indexInSlice(slice []*html.Node, node *html.Node) int { |
no test coverage detected
searching dependent graphs…