trying VERCEL_URL in getPropertymeta

This commit is contained in:
Khalim Conn-Kowlessar 2023-08-02 14:11:21 +01:00
parent 234c9c53a8
commit 52cb8790a6
2 changed files with 2 additions and 1 deletions

View file

@ -4,7 +4,8 @@ export async function getPropertyMeta(
propertyId: string
): Promise<PropertyMeta> {
const url =
process.env.URL + `/api/building-passport/property-meta/${propertyId}`;
(process.env.URL || process.env.VERCEL_URL) +
`/api/building-passport/property-meta/${propertyId}`;
const response = await fetch(url, {
method: "GET",