Skip to content

Commit

Permalink
fix: hidden useless error
Browse files Browse the repository at this point in the history
  • Loading branch information
HuberTRoy committed Jan 15, 2024
1 parent cbbcf32 commit f842a6b
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/hooks/useStudio.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,12 @@ export function useStudioEnabled() {

const checkStudioEnabled = useCallback(async () => {
if (!contracts || !account) return;
const studioEnabled = await contracts.queryRegistry.creatorWhitelist(account);
setStudioEnabled(studioEnabled);
try {
const studioEnabled = await contracts.queryRegistry.creatorWhitelist(account);
setStudioEnabled(studioEnabled);
} catch (e) {
// don't care this error
}
}, [contracts, account]);

useEffect(() => {
Expand Down

0 comments on commit f842a6b

Please sign in to comment.