diff --git a/requests_html.py b/requests_html.py index c8ca374..0a049d9 100644 --- a/requests_html.py +++ b/requests_html.py @@ -220,7 +220,7 @@ class BaseParser: try: href = link.attrs['href'].strip() - if href and not (href.startswith('#') and self.skip_anchors and href in ['javascript:;']): + if href and not (href.startswith('#') and self.skip_anchors) and not href.startswith('javascript:'): yield href except KeyError: pass