rss-parser
Advanced tools
Comparing version 3.7.5 to 3.7.6
@@ -264,9 +264,17 @@ "use strict"; | ||
} | ||
if(channel['itunes:keywords']) { | ||
let keywords=channel['itunes:keywords'][0]; | ||
if(keywords && typeof keywords._ === 'string'){ | ||
keywords=keywords._ | ||
if (channel['itunes:keywords']) { | ||
if (channel['itunes:keywords'].length > 1) { | ||
feed.itunes.keywords = channel['itunes:keywords'].map( | ||
keyword => keyword.$.text | ||
); | ||
} else { | ||
let keywords = channel['itunes:keywords'][0]; | ||
if (keywords && typeof keywords._ === 'string') { | ||
keywords = keywords._; | ||
} | ||
if (keywords) feed.itunes.keywords = keywords.split(','); | ||
} | ||
if(keywords)feed.itunes.keywords = keywords.split(","); | ||
} | ||
utils.copyFromXML(channel, feed.itunes, fields.podcastFeed); | ||
@@ -273,0 +281,0 @@ items.forEach((item, index) => { |
{ | ||
"name": "rss-parser", | ||
"version": "3.7.5", | ||
"version": "3.7.6", | ||
"main": "index.js", | ||
@@ -5,0 +5,0 @@ "types": "index.d.ts", |
@@ -7,2 +7,2 @@ { | ||
} | ||
} | ||
} |
@@ -264,2 +264,6 @@ "use strict"; | ||
it('should parse itunes keywords as array', function(done) { | ||
testParseForFile('itunes-keywords-array', 'rss', done); | ||
}); | ||
it('should parse giantbomb-podcast', function(done) { | ||
@@ -266,0 +270,0 @@ testParseForFile('giantbomb-podcast', 'rss', done); |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7188577
71
41133