actually fix transcripts

This commit is contained in:
2024-12-10 16:29:20 -06:00
parent bb57e68381
commit 1994953de8

View File

@@ -25,6 +25,7 @@ class PodcastFeed {
const feed = new Podcast({
title: data.title,
description: data.description,
customNamespaces: {podcast:"https://github.com/Podcastindex-org/podcast-namespace/blob/main/docs/1.0.md"},
feedUrl: `${data.site.url}${data.page.filePathStem}.xml`,
siteUrl: data.site.url,
imageUrl: data.site.imageUrl || `${data.site.url}${data.page.filePathStem}.jpg`,
@@ -62,11 +63,13 @@ class PodcastFeed {
// itunesDuration: duration,
}
if (episode.data.podcast.transcriptUrl) {
item.customElements.push({ 'podcast:transcript': {
url:episode.data.podcast.transcriptUrl,
item.customElements.push({ 'podcast:transcript': [{_attr:{
url:`${episode.data.podcast.transcriptUrl}`,
type:"application/x-subrip"
}
})}
}}]
})
console.log()
}
item = feed.addItem(item);
})