diff --git a/components/Flag.vue b/components/Flag.vue index d6cc10e6..f67c956f 100644 --- a/components/Flag.vue +++ b/components/Flag.vue @@ -29,12 +29,12 @@ }, computed: { link() { - if (!this.config.nouns.terms.enabled) { + if (!this.config.nouns.terms.enabled || !(this.config.nouns.terms.published || this.$isGranted('terms'))) { return null; } for (let term of this.terms || []) { - if (term.key.toLowerCase().includes(this.alt.toLowerCase())) { + if (term.key && term.key.toLowerCase().includes(this.alt.toLowerCase())) { return term.key; } if (term.term.toLowerCase().includes(this.name.toLowerCase())) { diff --git a/locale/pl/config.suml b/locale/pl/config.suml index b79978f4..6643ff8d 100644 --- a/locale/pl/config.suml +++ b/locale/pl/config.suml @@ -91,6 +91,7 @@ nouns: route: 'inkluzywny' terms: enabled: true + published: true categories: - 'orientacja seksualna' - 'orientacja romantyczna' diff --git a/routes/queerTerms.vue b/routes/queerTerms.vue index 3c1f1eeb..975c721a 100644 --- a/routes/queerTerms.vue +++ b/routes/queerTerms.vue @@ -1,5 +1,5 @@