Commit 7d72299d authored by Jérome Perrin's avatar Jérome Perrin Committed by Arnaud Fontaine

RSS: py3

parent c134e22f
......@@ -58,7 +58,7 @@ def getRssDataAsDict(context, url, username=None, password=None):
entry_dict['updated_parsed'] = entry.get('updated_parsed', None)
result['items'].append(entry_dict)
# sort by date
result['items'] = sorted(result['items'], key=lambda k: k['updated_parsed'])
result['items'] = sorted(result['items'], key=lambda k: k['updated_parsed'] or ())
result['items'].reverse()
result['status'] = 0
return result
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment