getCurrentLocation method

Future<OlaLatLng?> getCurrentLocation()

Implementation

Future<OlaLatLng?> getCurrentLocation() async {
  try {
    final result = await _invoke('getCurrentLocation');
    if (result is Map) return OlaLatLng.fromJson(result);
    return null;
  } catch (e) {
    debugPrint('Error getting current location: $e');
    return null;
  }
}