mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-12-27 05:03:07 +01:00
parent
3459d23a4d
commit
5d0de2d44e
@ -54,7 +54,7 @@ except ImportError:
|
|||||||
"#installing-beautiful-soup")
|
"#installing-beautiful-soup")
|
||||||
|
|
||||||
class DDG(callbacks.Plugin):
|
class DDG(callbacks.Plugin):
|
||||||
"""Searches results on DuckDuckGo."""
|
"""Searches for results on DuckDuckGo."""
|
||||||
threaded = True
|
threaded = True
|
||||||
|
|
||||||
def search(self, irc, msg, args, text):
|
def search(self, irc, msg, args, text):
|
||||||
@ -74,7 +74,6 @@ class DDG(callbacks.Plugin):
|
|||||||
# DuckDuckGo lite uses tables for everything. Each WEB result is made
|
# DuckDuckGo lite uses tables for everything. Each WEB result is made
|
||||||
# up of 3 <tr> tags:
|
# up of 3 <tr> tags:
|
||||||
tables = soup.find_all('table')
|
tables = soup.find_all('table')
|
||||||
regex = re.compile('.*!(sponsored).*')
|
|
||||||
|
|
||||||
webresults = tables[1].find_all('tr')
|
webresults = tables[1].find_all('tr')
|
||||||
if not webresults:
|
if not webresults:
|
||||||
|
Loading…
Reference in New Issue
Block a user