Skip to content

Commit

Permalink
fix: region ip service broken
Browse files Browse the repository at this point in the history
close #3309
  • Loading branch information
zhouhanseng committed Jun 29, 2021
1 parent d968c4a commit 17cc462
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/maskbook/src/plugins/ITO/UI/ITO.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,8 @@ export function ITO(props: ITO_Props) {
const { value: currentRegion, loading: loadingRegion } = useIPRegion()
const allowRegions = decodeRegionCode(regions)
const isRegionRestrict = checkRegionRestrict(allowRegions)
const isRegionAllow = !isRegionRestrict || (!loadingRegion && allowRegions.includes(currentRegion!.code))
const isRegionAllow =
!isRegionRestrict || !currentRegion || (!loadingRegion && allowRegions.includes(currentRegion.code))

//#region if qualified
const {
Expand Down

0 comments on commit 17cc462

Please sign in to comment.