diff --git a/files/routes/feeds.py b/files/routes/feeds.py
index 2d97ef0d2..a64a2827f 100644
--- a/files/routes/feeds.py
+++ b/files/routes/feeds.py
@@ -33,8 +33,12 @@ def feeds_user(sort='hot', t='all'):
with tag("title", type="text"):
text(f"{sort} posts from {domain}")
- doc.stag("link", href=SITE_FULL + request.full_path)
- doc.stag("link", href=SITE_FULL)
+ with tag("id"):
+ text(SITE_FULL + request.full_path)
+ with tag("updated"):
+ text(datetime.now().isoformat()+"Z")
+ doc.stag("link", rel="self", type="application/atom+xml", href=SITE_FULL + request.full_path)
+ doc.stag("link", rel="alternate", type="text/html", href=SITE_FULL)
for post in posts:
with tag("entry", ("xml:base", SITE_FULL + request.full_path)):
@@ -42,14 +46,14 @@ def feeds_user(sort='hot', t='all'):
text(post.realtitle(None))
with tag("id"):
- text(post.fullname)
+ text(post.permalink)
if (post.edited_utc):
with tag("updated"):
- text(datetime.utcfromtimestamp(post.edited_utc).isoformat())
+ text(datetime.utcfromtimestamp(post.edited_utc).isoformat()+"Z")
with tag("published"):
- text(datetime.utcfromtimestamp(post.created_utc).isoformat())
+ text(datetime.utcfromtimestamp(post.created_utc).isoformat()+"Z")
with tag("author"):
with tag("name"):
@@ -67,4 +71,4 @@ def feeds_user(sort='hot', t='all'):
with tag("content", type="html"):
doc.cdata(f'''
{post.realbody(None)}''')
- return Response( ""+ doc.getvalue(), mimetype="application/xml")
\ No newline at end of file
+ return Response( ""+ doc.getvalue(), mimetype="application/xml")