From a8b92819d1fcc70ae47cd54ec028310835a1cd0f Mon Sep 17 00:00:00 2001 From: advplyr Date: Mon, 20 Jan 2025 14:04:18 -0600 Subject: [PATCH] Update feed episode description to use CDATA --- server/models/FeedEpisode.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/server/models/FeedEpisode.js b/server/models/FeedEpisode.js index a2540a20..5a0dbac3 100644 --- a/server/models/FeedEpisode.js +++ b/server/models/FeedEpisode.js @@ -308,7 +308,6 @@ class FeedEpisode extends Model { const customElements = [ { 'itunes:author': this.author || null }, { 'itunes:duration': Math.round(Number(this.duration)) }, - { 'itunes:summary': this.description || null }, { 'itunes:explicit': !!this.explicit }, @@ -319,6 +318,9 @@ class FeedEpisode extends Model { // Remove empty custom elements return Object.values(element)[0] !== null }) + if (this.description) { + customElements.push({ 'itunes:summary': { _cdata: this.description } }) + } return { title: this.title,