Skip to content

The open alternative to Salesforce, designed for AI.

Fix app env var fetching (#18199)

Baptiste Devessierb339c93699fc
diff --git a/packages/twenty-front/src/pages/settings/applications/hooks/useUpdateOneApplicationVariable.ts b/packages/twenty-front/src/pages/settings/applications/hooks/useUpdateOneApplicationVariable.ts
index 520227c5d9c..df9e58c35c3 100644
--- a/packages/twenty-front/src/pages/settings/applications/hooks/useUpdateOneApplicationVariable.ts
+++ b/packages/twenty-front/src/pages/settings/applications/hooks/useUpdateOneApplicationVariable.ts
@@ -1,17 +1,7 @@
-import { useMutation } from '@apollo/client';
-import { useApolloCoreClient } from '@/object-metadata/hooks/useApolloCoreClient';
-import { UPDATE_ONE_APPLICATION_VARIABLE } from '@/application-variables/graphql/mutations/updateOneApplicationVariable';
-import {
- type UpdateOneApplicationVariableMutation,
- type UpdateOneApplicationVariableMutationVariables,
-} from '~/generated-metadata/graphql';
+import { useUpdateOneApplicationVariableMutation } from '~/generated-metadata/graphql';
export const useUpdateOneApplicationVariable = () => {
- const apolloMetadataClient = useApolloCoreClient();
- const [mutate] = useMutation<
- UpdateOneApplicationVariableMutation,
- UpdateOneApplicationVariableMutationVariables
- >(UPDATE_ONE_APPLICATION_VARIABLE, { client: apolloMetadataClient });
+ const [mutate] = useUpdateOneApplicationVariableMutation();
const updateOneApplicationVariable = async ({
key,