Commits

Shitiz Garg  committed 2aa4f4e

Minor fixes for atom feed

  • Participants
  • Parent commits 98ff5e7

Comments (0)

Files changed (3)

File MoinMoin/apps/feed/views.py

                      updated=datetime.fromtimestamp(rev.meta[MTIME]),
                     )
         content = feed.to_string()
-        # Hack to add XSLT stylesheet declaration since AtomFeed doens't allow this
+        # Hack to add XSLT stylesheet declaration since AtomFeed doesn't allow this
         content = content.split("\n")
         content.insert(1, render_template('atom.html', get='xml'))
         content = "\n".join(content)
         if cid is not None:
             app.cache.set(cid, content)
-    return Response(content, content_type='application/atom+xml')
+    return Response(content, content_type='application/atom+xml')

File MoinMoin/items/__init__.py

     _render_data_diff_text = _render_data_diff
     _render_data_diff_raw = _render_data_diff
     _render_data_diff_atom = _render_data_diff
-    
+
     def _convert(self, doc):
         return _("Impossible to convert the data to the contenttype: %(contenttype)s",
                  contenttype=request.values.get('contenttype'))
     def data_storage_to_internal(self, data):
         """ convert data from storage format to memory format """
         return data.decode(config.charset).replace(u'\r\n', u'\n')
- 
+
     def _get_data_diff_html(self, oldrev, newrev, template):
         from MoinMoin.util.diff_html import diff
         old_text = self.data_storage_to_internal(oldrev.data.read())
                                newrev=newrev,
                                diffs=diffs,
                                )
-                               
+
     def _render_data_diff_atom(self, oldrev, newrev):
         """ renders diff in HTML for atom feed """
         return self._get_data_diff_html(oldrev, newrev, 'diff_text_atom.html')
 
     def _render_data_diff(self, oldrev, newrev):
         return Markup(self._get_data_diff_html(oldrev, newrev, 'diff_text.html'))
-                                      
+
     def _render_data_diff_text(self, oldrev, newrev):
         from MoinMoin.util import diff_text
         oldlines = self.data_storage_to_internal(oldrev.data.read()).split('\n')

File MoinMoin/templates/atom.html

 {%- elif get == 'comment_cont_merge' -%}
     <p style="font-size: 14px">...{{ comment }}</p> <br /> {{ content }}
 {%- elif get == 'first_revision' -%}
-    <p style='font-style: italic;'>{{ _('First revision') }}</p><br />{{ content }}
+    <p style="font-style: italic;">{{ _('First revision') }}</p><br />{{ content }}
 {%- endif -%}