diff --git a/public/astropaper-og.jpg b/public/astropaper-og.jpg deleted file mode 100644 index 3b351f9..0000000 Binary files a/public/astropaper-og.jpg and /dev/null differ diff --git a/src/config.ts b/src/config.ts index 5f96932..36abc49 100644 --- a/src/config.ts +++ b/src/config.ts @@ -5,7 +5,7 @@ export const SITE: Site = { author: "Chris Watson", desc: "Personal website and blog of Chris Watson", title: "Watzon Does Tech", - ogImage: "astropaper-og.jpg", + ogImage: "watzon-tech-og.png", lightAndDarkMode: true, postPerPage: 5, }; diff --git a/src/layouts/PostDetails.astro b/src/layouts/PostDetails.astro index 4524724..ab9ca10 100644 --- a/src/layouts/PostDetails.astro +++ b/src/layouts/PostDetails.astro @@ -17,8 +17,7 @@ const { title, author, description, ogImage, canonicalURL, date, tags } = post.d const { Content } = await post.render(); -const ogUrl = new URL(ogImage ? ogImage : `${title}.png`, Astro.url.origin) - .href; +const ogUrl = ogImage ? new URL(ogImage, Astro.url.origin).href : undefined; ---