From e90e10587bf801fbf340bfbc4cdcafd4e5b98ce0 Mon Sep 17 00:00:00 2001 From: Pablo Lara Date: Wed, 6 Nov 2024 14:06:14 +0100 Subject: [PATCH] chore: remove unused console log --- .../workflow/forms/connect-account-form.tsx | 1 - .../workflow/forms/test-connection-form.tsx | 17 ++++++----------- 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/components/providers/workflow/forms/connect-account-form.tsx b/components/providers/workflow/forms/connect-account-form.tsx index 1c0430bf41..9a0825ef66 100644 --- a/components/providers/workflow/forms/connect-account-form.tsx +++ b/components/providers/workflow/forms/connect-account-form.tsx @@ -49,7 +49,6 @@ export const ConnectAccountForm = () => { formValues.providerAlias = `${formValues.providerType}:${month}/${day}/${year}`; } - console.log({ formValues }); const formData = new FormData(); Object.entries(formValues).forEach( diff --git a/components/providers/workflow/forms/test-connection-form.tsx b/components/providers/workflow/forms/test-connection-form.tsx index 6341faaf34..6d7ca16dbe 100644 --- a/components/providers/workflow/forms/test-connection-form.tsx +++ b/components/providers/workflow/forms/test-connection-form.tsx @@ -135,33 +135,28 @@ export const TestConnectionForm = ({ const onResetCredentials = async () => { setIsResettingCredentials(true); - // Check if provider has no credentials + + // Check if provider the provider has no credentials const providerSecretId = providerData?.data?.relationships?.secret?.data?.id; const hasNoCredentials = !providerSecretId; - console.log({ providerSecretId }, "providerSecretId"); - console.log({ hasNoCredentials }, "hasNoCredentials"); if (hasNoCredentials) { // If no credentials, redirect to add credentials page - console.log("no credentials"); - // router.push( - // `/providers/add-credentials?type=${providerType}&id=${providerId}`, - // ); + router.push( + `/providers/add-credentials?type=${providerType}&id=${providerId}`, + ); return; } - // If has credentials, delete them first + // If provider has credentials, delete them first try { - // This function will need to be implemented await deleteCredentials(providerSecretId); // After successful deletion, redirect to add credentials page - console.log("deleted credentials with success"); router.push( `/providers/add-credentials?type=${providerType}&id=${providerId}`, ); } catch (error) { - // Handle error appropriately console.error("Failed to delete credentials:", error); } finally { setIsResettingCredentials(false);