Skip to content

Commit

Permalink
Always discard DOM search results (#1311)
Browse files Browse the repository at this point in the history
  • Loading branch information
bno1 committed Aug 5, 2023
1 parent ae1cb79 commit d218b16
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions query.go
Expand Up @@ -329,6 +329,10 @@ func BySearch(s *Selector) {
return nil, err
}

defer func() {
_ = dom.DiscardSearchResults(id).Do(ctx)
}()

if count < 1 {
return []cdp.NodeID{}, nil
}
Expand Down

0 comments on commit d218b16

Please sign in to comment.