From e03e6c86ee072f918c64c7591f7caa3f06978487 Mon Sep 17 00:00:00 2001 From: Gyula Soos Date: Tue, 14 Jun 2022 17:02:27 +0100 Subject: [PATCH 1/2] prioritise images from itunes over the node.images --- index.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/index.js b/index.js index 0994e93..9d9b7ee 100644 --- a/index.js +++ b/index.js @@ -104,15 +104,14 @@ const buildOptions = exports.buildOptions = function (params) { const GET = exports.GET = { imageURL: function (node) { + if (node["itunes:image"]) { + return node["itunes:image"][0]['$'].href + } if (node.image) { return node.image[0].url[0] } - if (node["itunes:image"]) { - return node["itunes:image"][0]['$'].href - } - return undefined }, From bfee64e19f48fe295a75b661eb0e48d96fba588f Mon Sep 17 00:00:00 2001 From: Gyula Soos Date: Tue, 14 Jun 2022 17:11:53 +0100 Subject: [PATCH 2/2] increase version number --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index ccca555..6d344ea 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "podcast-feed-parser", - "version": "1.0.4", + "version": "1.0.5", "description": "A highly customizable package for fetching and parsing podcast feeds into simple and manageable JavaScript objects. For use with node and in the browser.", "main": "index.js", "scripts": {