Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Directions.available bug #47

Open
Jonathan64340 opened this issue Jul 29, 2022 · 1 comment
Open

Directions.available bug #47

Jonathan64340 opened this issue Jul 29, 2022 · 1 comment

Comments

@Jonathan64340
Copy link

Jonathan64340 commented Jul 29, 2022

Hello everybody,

Today I'm working on a navigation app, and we use @nativescript/directions 2.0.2.

Since our last upgrade, Directions.available() returns false, but it should return true, and when (for testing) we call directly Directions.navigate(), the navigation app opens correctly.

let directions = new Directions();
directions.available().then(available => {
    console.log({ available })             // return false
    if (true) {                            // force to enter and it
        directions.navigate({              // it works despite the available = false !!!
            to: {
                lat: parseFloat(this.totem.latitude),
                lng: parseFloat(this.totem.longitude),
            }
        }).then(() => { }, () => {
            GlobalService.toast(localize('app.gps_unavailable'));
        });
    } else {
        GlobalService.toast(localize('app.gps_unavailable'));
    }
});

Can you help me please ?
Best regards

@alexdomingues
Copy link

I'm having the same problem on android emulator and android real device with the same version of directions. For iOS it's working fine in emulator.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants