mirror of
https://github.com/formbricks/formbricks.git
synced 2025-12-30 10:19:51 -06:00
fix: license cache issue (#4337)
This commit is contained in:
@@ -34,7 +34,7 @@ export const EditSegmentModal = ({
|
||||
}: EditSegmentModalProps) => {
|
||||
const t = useTranslations();
|
||||
const SettingsTab = () => {
|
||||
if (isAdvancedTargetingAllowed || false) {
|
||||
if (isAdvancedTargetingAllowed) {
|
||||
return (
|
||||
<SegmentSettings
|
||||
attributeClasses={attributeClasses}
|
||||
|
||||
@@ -4,10 +4,11 @@ import {
|
||||
TEnterpriseLicenseFeatures,
|
||||
} from "@/modules/ee/license-check/types/enterprise-license";
|
||||
import { HttpsProxyAgent } from "https-proxy-agent";
|
||||
import { unstable_after as after } from "next/server";
|
||||
import fetch from "node-fetch";
|
||||
import { cache as reactCache } from "react";
|
||||
import { prisma } from "@formbricks/database";
|
||||
import { cache } from "@formbricks/lib/cache";
|
||||
import { cache, revalidateTag } from "@formbricks/lib/cache";
|
||||
import {
|
||||
E2E_TESTING,
|
||||
ENTERPRISE_LICENSE_KEY,
|
||||
@@ -48,7 +49,6 @@ const setPreviousResult = async (previousResult: {
|
||||
lastChecked: Date;
|
||||
features: TEnterpriseLicenseFeatures | null;
|
||||
}) => {
|
||||
// revalidateTag(PREVIOUS_RESULTS_CACHE_TAG_KEY);
|
||||
const { lastChecked, active, features } = previousResult;
|
||||
|
||||
await cache(
|
||||
@@ -62,6 +62,10 @@ const setPreviousResult = async (previousResult: {
|
||||
tags: [PREVIOUS_RESULTS_CACHE_TAG_KEY],
|
||||
}
|
||||
)();
|
||||
|
||||
after(() => {
|
||||
revalidateTag(PREVIOUS_RESULTS_CACHE_TAG_KEY);
|
||||
});
|
||||
};
|
||||
|
||||
const fetchLicenseForE2ETesting = async (): Promise<{
|
||||
|
||||
@@ -22,6 +22,7 @@ const nextConfig = {
|
||||
poweredByHeader: false,
|
||||
experimental: {
|
||||
serverComponentsExternalPackages: ["@aws-sdk"],
|
||||
after: true,
|
||||
instrumentationHook: true,
|
||||
outputFileTracingIncludes: {
|
||||
"app/api/packages": ["../../packages/js-core/dist/*", "../../packages/surveys/dist/*"],
|
||||
|
||||
Reference in New Issue
Block a user