Skip to content

Commit

Permalink
chore: tweak enhanced provider hook
Browse files Browse the repository at this point in the history
  • Loading branch information
magiziz committed May 7, 2024
1 parent 9a40207 commit 1410c93
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/rainbowkit/src/hooks/useMainnetEnsName.ts
Expand Up @@ -31,6 +31,8 @@ export function useMainnetEnsName(address?: Address) {
queryKey: createQueryKey('address', address),
queryFn: () => getEnhancedProviderEnsName({ address: address! }),
enabled: !mainnetConfigured && !!address,
staleTime: 10 * (60 * 1_000), // 10 minutes
retry: 1, // Retry once before returning undefined if the request fails
});

return ensName || enhancedProviderEnsName;
Expand Down

0 comments on commit 1410c93

Please sign in to comment.