prevent whoogle links from opening in a new tab.

This commit is contained in:
jacr13 2021-04-09 19:31:49 +02:00
parent a97bbc5475
commit ba296f056a

View File

@ -206,7 +206,9 @@ class Filter:
# Temporarily removing all links to that tab for now.
link.decompose()
return
elif self.new_tab:
elif (self.new_tab
and not href.startswith('/search')
and not href.startswith('/?safe')):
link['target'] = '_blank'
result_link = urlparse.urlparse(href)