diff --git a/src/routes/sitemap.xml/+server.js b/src/routes/sitemap.xml/+server.js index b26eafa..3b831e4 100644 --- a/src/routes/sitemap.xml/+server.js +++ b/src/routes/sitemap.xml/+server.js @@ -6,7 +6,7 @@ export async function GET({ fetch, setHeaders }) { const site = 'https://koreanskincareandclinic.com'; const response = await fetch('https://api.koreanskincareandclinic.com/api/product'); if (!response.ok) { - throw new Error('Failed to fetch posts.'); + throw new Error('Failed to fetch product.'); } const products = await response.json(); @@ -17,7 +17,7 @@ export async function GET({ fetch, setHeaders }) { daily 0.7 -${products.products +${products .map( (/** @type {{ id: any;slug:string; published_at: string; }} */ product) => `