changeset 1050:6c98c0baa038

pages (common/blog/atom.xml): don't use query elements in request_uri: when used in self link, some search engine bots (google bot at least) are trying to retrieve page with "comments_max" query argument, which is then returned in the feed in self link, and it get added in a infinite loop.
author Goffi <goffi@goffi.org>
date Thu, 25 Jan 2018 08:17:29 +0100
parents 6b1e1f13a299
children d3ac6fb10fd5
files src/pages/common/blog/atom.xml/page_meta.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/pages/common/blog/atom.xml/page_meta.py	Thu Jan 25 07:54:27 2018 +0100
+++ b/src/pages/common/blog/atom.xml/page_meta.py	Thu Jan 25 08:17:29 2018 +0100
@@ -23,7 +23,7 @@
     yield blog_page.prepare_render(self, request)
     items = data[u'items']
 
-    template_data[u'request_uri'] = self.host.getExtBaseURL(request, request.uri.decode('utf-8'))
+    template_data[u'request_uri'] = self.host.getExtBaseURL(request, request.path.decode('utf-8'))
     template_data[u'xmpp_uri'] = uri.buildXMPPUri(u'pubsub',
                                                  subtype=u'microblog',
                                                  path=service.full(),