Skip to content

Commit

Permalink
fix: catch cancel connect
Browse files Browse the repository at this point in the history
  • Loading branch information
2fd committed Mar 25, 2020
1 parent 71fd0a9 commit 0e053e8
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/hooks/useProfile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,11 @@ export default function useProfile() {
return result
}

CURRENT_PROFILE_LOADER = identify()
CURRENT_PROFILE_LOADER = identify().catch((err) => {
CURRENT_PROFILE_LOADER = null
console.error(err);
return null
})

patchState({ loading: true })

Expand Down

0 comments on commit 0e053e8

Please sign in to comment.