summaryrefslogtreecommitdiff
path: root/searx/engines/google_news.py
diff options
context:
space:
mode:
authormisnyo <misnyo@users.noreply.github.com>2017-09-04 17:48:25 +0200
committerGitHub <noreply@github.com>2017-09-04 17:48:25 +0200
commitc3232b0e1a82315e5936fb3c0731548efd66a0b3 (patch)
tree2ba9db54ae7b36ae138285fc2a185afaa7e570ac /searx/engines/google_news.py
parent01330f71cd60cab6c1ce9a19c28c2729f2d02344 (diff)
parent688801076d173de67bf4543ca289a35f28b6c245 (diff)
Merge branch 'master' into nyaa
Diffstat (limited to 'searx/engines/google_news.py')
-rw-r--r--searx/engines/google_news.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/searx/engines/google_news.py b/searx/engines/google_news.py
index 7344b5289..8881d0dad 100644
--- a/searx/engines/google_news.py
+++ b/searx/engines/google_news.py
@@ -67,8 +67,8 @@ def response(resp):
for result in dom.xpath('//div[@class="g"]|//div[@class="g _cy"]'):
try:
r = {
- 'url': result.xpath('.//div[@class="_cnc"]//a/@href')[0],
- 'title': ''.join(result.xpath('.//div[@class="_cnc"]//h3//text()')),
+ 'url': result.xpath('.//a[@class="l _PMs"]')[0].attrib.get("href"),
+ 'title': ''.join(result.xpath('.//a[@class="l _PMs"]//text()')),
'content': ''.join(result.xpath('.//div[@class="st"]//text()')),
}
except: