Skip to content

Beautiful Open-Source Form Builder

Fix meta tags robots form templates

Julien Nahum6e48cf6d4c98
diff --git a/resources/js/pages/templates/show.vue b/resources/js/pages/templates/show.vue
index 043f24f3f..97c2c9ae3 100644
--- a/resources/js/pages/templates/show.vue
+++ b/resources/js/pages/templates/show.vue
@@ -264,11 +264,14 @@ export default {
return this.template.image_url
},
metaTags () {
- return (this.template && this.template.publicly_listed) ? [] : [{ name: 'robots', content: 'noindex' }]
+ if (!this.template) {
+ return [];
+ }
+ return this.template.publicly_listed ? [] : [{ name: 'robots', content: 'noindex' }]
},
createFormWithTemplateUrl () {
if(this.authenticated) {
- return '/forms/create?template=' + this.template?.slug
+ return '/forms/create?template=' + this.template?.slug
}
return '/forms/create/guest?template=' + this.template?.slug
}