1
0
Fork 0
forked from github/pelican

Remove Atom summaries when they are unnecessary

Do not include a summary tag to Atom entries when:
- the summary is empty
- the summary and the full content are the same

Fixes #2403
This commit is contained in:
Nicolas Le Manchet 2018-10-03 21:53:24 +02:00
commit 1b8a7826c4
22 changed files with 122 additions and 274 deletions

View file

@ -1,4 +1,3 @@
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom"><title>A Pelican Blog</title><link href="/" rel="alternate"></link><link href="/feeds/all-fr.atom.xml" rel="self"></link><id>/</id><updated>2012-02-29T00:00:00+00:00</updated><entry><title>Deuxième article</title><link href="/second-article-fr.html" rel="alternate"></link><published>2012-02-29T00:00:00+00:00</published><updated>2012-02-29T00:00:00+00:00</updated><author><name></name></author><id>tag:None,2012-02-29:/second-article-fr.html</id><summary type="html">&lt;p&gt;Ceci est un article, en français.&lt;/p&gt;
</summary><content type="html">&lt;p&gt;Ceci est un article, en français.&lt;/p&gt;
<feed xmlns="http://www.w3.org/2005/Atom"><title>A Pelican Blog</title><link href="/" rel="alternate"></link><link href="/feeds/all-fr.atom.xml" rel="self"></link><id>/</id><updated>2012-02-29T00:00:00+00:00</updated><entry><title>Deuxième article</title><link href="/second-article-fr.html" rel="alternate"></link><published>2012-02-29T00:00:00+00:00</published><updated>2012-02-29T00:00:00+00:00</updated><author><name></name></author><id>tag:None,2012-02-29:/second-article-fr.html</id><content type="html">&lt;p&gt;Ceci est un article, en français.&lt;/p&gt;
</content><category term="foo"></category><category term="bar"></category><category term="baz"></category></entry></feed>