diff --git a/packages/next-utils/package.json b/packages/next-utils/package.json index 8ac0f3b..b4956bd 100644 --- a/packages/next-utils/package.json +++ b/packages/next-utils/package.json @@ -1,6 +1,6 @@ { "name": "@mintel/next-utils", - "version": "1.7.11", + "version": "1.7.12", "publishConfig": { "access": "public", "registry": "https://npm.infra.mintel.me" diff --git a/packages/next-utils/src/directus.ts b/packages/next-utils/src/directus.ts index 3b5ae78..da90169 100644 --- a/packages/next-utils/src/directus.ts +++ b/packages/next-utils/src/directus.ts @@ -21,7 +21,7 @@ export function createMintelDirectusClient( // 1. If an explicit URL is provided, use it. if (url) { - return createDirectus(url).with(rest()).with(authentication()); + return createDirectus(url).with(rest()).with(authentication()); } // 2. On server: Prioritize INTERNAL_DIRECTUS_URL, fallback to DIRECTUS_URL @@ -30,7 +30,9 @@ export function createMintelDirectusClient( process.env.INTERNAL_DIRECTUS_URL || process.env.DIRECTUS_URL || "http://localhost:8055"; - return createDirectus(directusUrl).with(rest()).with(authentication()); + return createDirectus(directusUrl) + .with(rest()) + .with(authentication()); } // 3. In browser: Use a proxy path if we are on a different origin, @@ -41,7 +43,7 @@ export function createMintelDirectusClient( ? `${window.location.origin}${proxyPath}` : proxyPath; - return createDirectus(browserUrl).with(rest()).with(authentication()); + return createDirectus(browserUrl).with(rest()).with(authentication()); } /**