Fix geo debug bug
This commit is contained in:
@@ -183,7 +183,7 @@ export function useGeolocation() {
|
|||||||
if (__DEV__) {
|
if (__DEV__) {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
window.setGeolocation = (geo: Device['geolocation']) => {
|
window.setGeolocation = (geo: Device['geolocation']) => {
|
||||||
if (!geo?.countryCode || !geo?.isAgeRestrictedGeo) {
|
if (!geo?.countryCode || typeof geo?.isAgeRestrictedGeo !== 'boolean') {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
`Expected {countryCode: string, isAgeRestrictedGeo: boolean}`,
|
`Expected {countryCode: string, isAgeRestrictedGeo: boolean}`,
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user