diff options
author | Leonard Richardson <leonardr@segfault.org> | 2023-03-23 16:59:27 -0400 |
---|---|---|
committer | Leonard Richardson <leonardr@segfault.org> | 2023-03-23 16:59:27 -0400 |
commit | a342497cb81f01384d61e467daf91540369d4fc3 (patch) | |
tree | d95f0bc768cf5a78b99b3ea4290cdd8369e1916b /bs4/__init__.py | |
parent | c91087b78b3584b1e696056bc2ad14e34ebd689e (diff) |
Found and removed accidental calls to find(), greatly improving performance.
Diffstat (limited to 'bs4/__init__.py')
-rw-r--r-- | bs4/__init__.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/bs4/__init__.py b/bs4/__init__.py index 01fca6d..5e1bebe 100644 --- a/bs4/__init__.py +++ b/bs4/__init__.py @@ -469,6 +469,7 @@ class BeautifulSoup(Tag): self.open_tag_counter = Counter() self.preserve_whitespace_tag_stack = [] self.string_container_stack = [] + self._most_recent_element = None self.pushTag(self) def new_tag(self, name, namespace=None, nsprefix=None, attrs={}, |