diff --git a/client/components/ui/VueTrix.vue b/client/components/ui/VueTrix.vue index 2687d934a..0836df154 100644 --- a/client/components/ui/VueTrix.vue +++ b/client/components/ui/VueTrix.vue @@ -318,10 +318,8 @@ export default { } }, handleAttachmentAdd(event) { - // Prevent pasting in images from the browser - if (!event.attachment.file) { - event.attachment.remove() - } + // Prevent pasting in images/any files from the browser + event.attachment.remove() } }, mounted() { diff --git a/server/managers/PodcastManager.js b/server/managers/PodcastManager.js index 052ba8b33..625688c97 100644 --- a/server/managers/PodcastManager.js +++ b/server/managers/PodcastManager.js @@ -384,7 +384,17 @@ class PodcastManager { Logger.error(`[PodcastManager] checkPodcastForNewEpisodes no feed url for ${podcastLibraryItem.media.title} (ID: ${podcastLibraryItem.id})`) return null } - const feed = await getPodcastFeed(podcastLibraryItem.media.feedURL) + const feed = await Promise.race([ + getPodcastFeed(podcastLibraryItem.media.feedURL), + new Promise((_, reject) => + // The added second is to make sure that axios can fail first and only falls back later + setTimeout(() => reject(new Error('Timeout. getPodcastFeed seemed to timeout but not triggering the timeout.')), global.PodcastDownloadTimeout + 1000) + ) + ]).catch((error) => { + Logger.error(`[PodcastManager] checkPodcastForNewEpisodes failed to fetch feed for ${podcastLibraryItem.media.title} (ID: ${podcastLibraryItem.id}):`, error) + return null + }) + if (!feed?.episodes) { Logger.error(`[PodcastManager] checkPodcastForNewEpisodes invalid feed payload for ${podcastLibraryItem.media.title} (ID: ${podcastLibraryItem.id})`, feed) return null