Skip to content

Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.

Add try-catch to syncLicenseKeyOnPremFeatures

carlosmonastyrski064322936b30
diff --git a/backend/src/ee/services/license/license-service.ts b/backend/src/ee/services/license/license-service.ts
index 7270dd1213..ca6c2a6991 100644
--- a/backend/src/ee/services/license/license-service.ts
+++ b/backend/src/ee/services/license/license-service.ts
@@ -87,10 +87,14 @@ export const licenseServiceFactory = ({
);
const syncLicenseKeyOnPremFeatures = async () => {
- const {
- data: { currentPlan }
- } = await licenseServerOnPremApi.request.get<{ currentPlan: TFeatureSet }>("/api/license/v1/plan");
- onPremFeatures = currentPlan;
+ try {
+ const {
+ data: { currentPlan }
+ } = await licenseServerOnPremApi.request.get<{ currentPlan: TFeatureSet }>("/api/license/v1/plan");
+ onPremFeatures = currentPlan;
+ } catch (error) {
+ logger.error(error, "Failed to synchronize license key features");
+ }
};
const init = async () => {