diff --git a/packages/react-app-revamp/hooks/useCastVotes/index.ts b/packages/react-app-revamp/hooks/useCastVotes/index.ts index d10b5f491..dcc782aa1 100644 --- a/packages/react-app-revamp/hooks/useCastVotes/index.ts +++ b/packages/react-app-revamp/hooks/useCastVotes/index.ts @@ -248,7 +248,12 @@ export function useCastVotes() { } async function performAnalytics(params: CombinedAnalyticsParams) { - await Promise.all([addUserActionAnalytics(params), updateRewardAnalyticsIfNeeded(params)]); + try { + await addUserActionAnalytics(params); + await updateRewardAnalyticsIfNeeded(params); + } catch (error) { + console.error("Error in performAnalytics:", error); + } } return { diff --git a/packages/react-app-revamp/hooks/useSubmitProposal/index.ts b/packages/react-app-revamp/hooks/useSubmitProposal/index.ts index 3e8b62d15..2328de3b7 100644 --- a/packages/react-app-revamp/hooks/useSubmitProposal/index.ts +++ b/packages/react-app-revamp/hooks/useSubmitProposal/index.ts @@ -237,7 +237,12 @@ export function useSubmitProposal() { } async function performAnalytics(params: CombinedAnalyticsParams) { - await Promise.all([addUserActionAnalytics(params), updateRewardAnalyticsIfNeeded(params)]); + try { + await addUserActionAnalytics(params); + await updateRewardAnalyticsIfNeeded(params); + } catch (error) { + console.error("Error in performAnalytics:", error); + } } return {