diff js/background.js @ 14:376a0e415bba

Properly handle non-text content in Atom feed elements The title, subtitle, summary and content elements of Atom feeds can all have non-text content. When parsing title and subtitle elements HTML and XHTML content will be stripped of any markup in order to keep it simple. In summary and content elements markup will be preserved. Element content of any other type as well as remote content in content elements will be ignored.
author Guido Berhoerster <guido+feed-preview@berhoerster.name>
date Mon, 10 Dec 2018 16:38:11 +0100
parents a4590add4901
children a59d322e5826
line wrap: on
line diff
--- a/js/background.js	Sat Dec 08 12:12:18 2018 +0100
+++ b/js/background.js	Mon Dec 10 16:38:11 2018 +0100
@@ -48,7 +48,10 @@
 const FEED_MAGIC = [
     '<rss',
     '<feed',
-    ...Object.values(feedParser.XMLNS)
+    feedParser.XMLNS.ATOM03,
+    feedParser.XMLNS.ATOM10,
+    feedParser.XMLNS.RSS09,
+    feedParser.XMLNS.RSS10
 ];
 var tabsFeeds = new Map();
 var tabsFeedPreviews = new Map();