From 5b30875564f7de54e38ac587db2d7ab6eff3b2a8 Mon Sep 17 00:00:00 2001 From: Jay Hodgson Date: Wed, 21 Jun 2023 15:54:32 -0700 Subject: [PATCH] fix duplicate call mistake --- .../ChallengeSubmission/ChallengeSubmission.tsx | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/packages/synapse-react-client/src/components/ChallengeSubmission/ChallengeSubmission.tsx b/packages/synapse-react-client/src/components/ChallengeSubmission/ChallengeSubmission.tsx index 3dc6960122..2d61ea4570 100644 --- a/packages/synapse-react-client/src/components/ChallengeSubmission/ChallengeSubmission.tsx +++ b/packages/synapse-react-client/src/components/ChallengeSubmission/ChallengeSubmission.tsx @@ -71,14 +71,13 @@ export function ChallengeSubmission({ // Use the existing accessToken if present to get the current user's profile / userId const { data: userProfile, isLoading: isProfileLoading } = - useGetCurrentUserProfile() - useGetCurrentUserProfile({ - enabled: isLoggedIn, - onError: () => { - setLoading(false) - setErrorMessage(`Error: Could not retrieve user profile`) - }, - }) + useGetCurrentUserProfile({ + enabled: isLoggedIn, + onError: () => { + setLoading(false) + setErrorMessage(`Error: Could not retrieve user profile`) + }, + }) // Retrieve the challenge associated with the projectId passed through props const { data: challenge } = useGetEntityChallenge(projectId, {