async Task ExecuteRefreshCommand(bool forceRefresh) { if (IsBusy) { return; } if (!await CheckConnectivityAsync()) { return; } IsBusy = true; try { Analytics.TrackEvent("SerchedForNearby"); var position = await GeolocationService.GetCurrentPositionAsync(); if (position == null) { throw new Exception("Unable to get location."); } ContactsGrouped.Clear(); var contacts = await DataService.GetNearbyAsync(position.Longitude, position.Latitude); if (contacts.Count() > 0) { ContactsGrouped.AddRange(contacts); } else { await Dialogs.AlertAsync(null, AppResources.NoCDAsNearby, AppResources.OK); } } catch (Exception ex) { Crashes.TrackError(ex); System.Diagnostics.Debug.WriteLine($"*** ERROR: {ex.Message}"); } finally { IsBusy = false; } }