Skip to content

Commit 8c209f6

Browse files
committed
temporary code for PR preview
1 parent 9e8c2d5 commit 8c209f6

1 file changed

Lines changed: 1 addition & 6 deletions

File tree

components/PageMeta.tsx

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
1-
import { type NextPageContext } from 'next';
21
import Head from 'next/head';
32

43
import { BASE_META } from '~/util/Constants';
5-
import getApiUrl from '~/util/getApiUrl';
64

75
type PageMetaProps = {
86
title?: string;
@@ -23,10 +21,7 @@ export default function PageMeta({
2321
? `Search results for keyword: '${parsedSearchQuery}'`
2422
: description;
2523

26-
const socialImage = getApiUrl(
27-
`/proxy/og?title=${encodeURIComponent(pageTitle)}&description=${encodeURIComponent(finalDescription)}`,
28-
{} as NextPageContext
29-
);
24+
const socialImage = `https://${window.location.host}/api/proxy/og?title=${encodeURIComponent(pageTitle)}&description=${encodeURIComponent(finalDescription)}`;
3025

3126
return (
3227
<Head>

0 commit comments

Comments
 (0)