From d0c02a801ad211cddb3a7ea8abde6f8e0d9abf73 Mon Sep 17 00:00:00 2001 From: advplyr Date: Fri, 8 Sep 2023 14:03:12 -0500 Subject: [PATCH] Update open rss feed prevent indexing - dont include block tags when not preventing indexing --- client/components/modals/rssfeed/OpenCloseModal.vue | 5 +++++ server/objects/FeedMeta.js | 7 +++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/client/components/modals/rssfeed/OpenCloseModal.vue b/client/components/modals/rssfeed/OpenCloseModal.vue index f5fe647c..c4ec909c 100644 --- a/client/components/modals/rssfeed/OpenCloseModal.vue +++ b/client/components/modals/rssfeed/OpenCloseModal.vue @@ -132,6 +132,8 @@ export default { return } + this.processing = true + const payload = { serverAddress: window.origin, slug: this.newFeedSlug, @@ -151,6 +153,9 @@ export default { const errorMsg = error.response ? error.response.data : null this.$toast.error(errorMsg || 'Failed to open RSS Feed') }) + .finally(() => { + this.processing = false + }) }, copyToClipboard(str) { this.$copyToClipboard(str, this) diff --git a/server/objects/FeedMeta.js b/server/objects/FeedMeta.js index 908d64fa..307e12bc 100644 --- a/server/objects/FeedMeta.js +++ b/server/objects/FeedMeta.js @@ -61,6 +61,10 @@ class FeedMeta { } getRSSData() { + const blockTags = [ + { 'itunes:block': 'yes' }, + { 'googleplay:block': 'yes' } + ] return { title: this.title, description: this.description || '', @@ -94,8 +98,7 @@ class FeedMeta { ] }, { 'itunes:explicit': !!this.explicit }, - { 'itunes:block': this.preventIndexing?"Yes":"No" }, - { 'googleplay:block': this.preventIndexing?"yes":"no" } + ...(this.preventIndexing ? blockTags : []) ] } }