From 6375904f88076bcd51cc97233b48ee2a64351834 Mon Sep 17 00:00:00 2001 From: Harlan Wilton Date: Sat, 17 Dec 2022 16:46:27 +1100 Subject: [PATCH] fix(robots): fix host --- server/routes/robots.txt.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/routes/robots.txt.ts b/server/routes/robots.txt.ts index 5a6bd76a..26d33aca 100644 --- a/server/routes/robots.txt.ts +++ b/server/routes/robots.txt.ts @@ -3,6 +3,6 @@ import { defineEventHandler, setHeader } from 'h3' export default defineEventHandler(async (event) => { setHeader(event, 'Content-Type', 'text/plain') - const debug = process.dev ? (`# Dev Mode: Generated by nuxt-seo-kit for ${config.host}. Indexing is ${config.indexable ? 'allowed' : 'disallowed'}\n`) : '' - return `${debug}User-agent: *\nDisallow: ${config.indexable ? `\nSitemap: ${config.host}/sitemap.xml` : '/'}` + const debug = process.dev ? (`# Dev Mode: Generated by nuxt-seo-kit for ${config.hostname}. Indexing is ${config.indexable ? 'allowed' : 'disallowed'}\n`) : '' + return `${debug}User-agent: *\nDisallow: ${config.indexable ? `\nSitemap: ${config.hostname}/sitemap.xml` : '/'}` })