From ae25950e7ff2421fdfd6df7d06a0f3653835df50 Mon Sep 17 00:00:00 2001 From: peintnermax Date: Wed, 18 Sep 2024 16:28:17 +0200 Subject: [PATCH] turn of caching --- apps/login/src/lib/zitadel.ts | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/apps/login/src/lib/zitadel.ts b/apps/login/src/lib/zitadel.ts index 9615595fccc..184bb9ffdc9 100644 --- a/apps/login/src/lib/zitadel.ts +++ b/apps/login/src/lib/zitadel.ts @@ -26,7 +26,6 @@ import { SearchQuery, SearchQuerySchema, } from "@zitadel/proto/zitadel/user/v2/query_pb"; -import { unstable_cache } from "next/cache"; import { PROVIDER_MAPPING } from "./idp"; const SESSION_LIFETIME_S = 3600; @@ -48,15 +47,18 @@ export const orgService = createOrganizationServiceClient(transport); export const settingsService = createSettingsServiceClient(transport); export async function getBrandingSettings(organization?: string) { - return unstable_cache( - async () => { - return await settingsService - .getBrandingSettings({ ctx: makeReqCtx(organization) }, {}) - .then((resp) => resp.settings); - }, - ["branding"], - { revalidate: 3600, tags: ["branding"] }, - )(); + return await settingsService + .getBrandingSettings({ ctx: makeReqCtx(organization) }, {}) + .then((resp) => resp.settings); + // return unstable_cache( + // async () => { + // return await settingsService + // .getBrandingSettings({ ctx: makeReqCtx(organization) }, {}) + // .then((resp) => resp.settings); + // }, + // ["branding"], + // { revalidate: 3600, tags: ["branding"] }, + // )(); } export async function getLoginSettings(orgId?: string) {