diff --git a/src/state/user/hooks.tsx b/src/state/user/hooks.tsx index 39227c98bf..ff1dac0025 100644 --- a/src/state/user/hooks.tsx +++ b/src/state/user/hooks.tsx @@ -524,12 +524,14 @@ export const useIsWhiteListKyberAI = () => { const loadingDebounced = useDebounce(isLoading, 500) || connectingWallet const participantInfo = isError || loadingDebounced || !account ? participantDefault : rawData - + // isWhitelist, isWaitList check account is hotfix for now, will remove utils backend fixed bug return { loading: loadingDebounced, isWhiteList: - isLogin && (participantInfo?.status === ParticipantStatus.WHITELISTED || userInfo?.data?.hasAccessToKyberAI), - isWaitList: isLogin && participantInfo?.status === ParticipantStatus.WAITLISTED, + !!account && + isLogin && + (participantInfo?.status === ParticipantStatus.WHITELISTED || userInfo?.data?.hasAccessToKyberAI), + isWaitList: !!account && isLogin && participantInfo?.status === ParticipantStatus.WAITLISTED, refetch, } }