Skip to content

iOS incorrectly detects Sygic GPS as Sygic Truck due to shared URL scheme #217

@noureen

Description

@noureen

Sygic has multiple apps, such as:

  • Sygic Truck (package: com.sygic.truck)
  • Sygic GPS Navigation (package: com.sygic.aura)

Currently, the map_launcher plugin only supports Sygic Truck, but on iOS it incorrectly detects Sygic GPS Navigation as Sygic Truck because both apps share the same URL scheme prefix (com.sygic.aura://).

This leads to inconsistent behavior between Android and iOS.

Android Behavior (Correct)

On Android, Sygic Truck is detected using the package name:
MapModel(MapType.sygicTruck, "Sygic Truck", "com.sygic.truck", "com.sygic.aura://")
Since Sygic GPS Navigation has a different package (com.sygic.aura), the plugin does NOT show Sygic Truck when only Sygic GPS is installed.

On iOS, availability is checked using only the URL prefix:

private func isMapAvailable(map: Map?) -> Bool {
    guard let urlPrefix = map.urlPrefix, let nsUrl = URL(string: urlPrefix) else {
        return false
    }
    return UIApplication.shared.canOpenURL(nsUrl)
}

And Sygic Truck is registered as:

Map(mapName: "Sygic Truck", mapType: MapType.sygicTruck, urlPrefix: "com.sygic.aura://")

Because Sygic GPS Navigation also responds to com.sygic.aura://, iOS incorrectly reports that Sygic Truck is installed. As a result:

  • iOS shows Sygic Truck even when only Sygic GPS is installed.
  • After v4.4.3, the app no longer crashes, but clicking Sygic Truck does nothing and does not open the Sygic app.

Impact

  • Users see Sygic Truck in the map list even when it is not installed.
  • Clicking the option does not open the Sygic app.
  • Developers must manually hide Sygic Truck to avoid broken UX.

Suggested Solutions
Option#1: Add support for multiple Sygic apps
Option#2: Restrict Sygic Truck detection on iOS and avoid showing Sygic Truck when only Sygic GPS is installed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions