From 3edabb96bba8af8ae53b6f9553389814f99a9ee6 Mon Sep 17 00:00:00 2001 From: VladiMihaylenko Date: Mon, 1 Aug 2016 12:53:45 +0300 Subject: [PATCH] [ios] Fixed sharing url. --- iphone/Maps/Classes/Share/MWMShareActivityItem.mm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/iphone/Maps/Classes/Share/MWMShareActivityItem.mm b/iphone/Maps/Classes/Share/MWMShareActivityItem.mm index 394e7dabc3..c6e3e878a2 100644 --- a/iphone/Maps/Classes/Share/MWMShareActivityItem.mm +++ b/iphone/Maps/Classes/Share/MWMShareActivityItem.mm @@ -66,8 +66,9 @@ NSString * httpGe0Url(NSString * shortUrl) return @""; }; - string const s = f.CodeGe0url(self.location.latitude, self.location.longitude, f.GetDrawScale(), - title(self.entity).UTF8String); + ms::LatLon const ll = self.entity ? self.entity.latlon : ms::LatLon(self.location.latitude, self.location.longitude); + string const s = f.CodeGe0url(ll.lat, ll.lon, f.GetDrawScale(), title(self.entity).UTF8String); + NSString * url = @(s.c_str()); if (!isShort) return url;