First of all, I did a little research but only found for Swift a native iOS answer.
The complete warning says:
This method can cause UI unresponsiveness if invoked on the main thread. Instead, consider waiting for the `-locationManagerDidChangeAuthorization:` callback and checking `authorizationStatus` first.
I have read that could be because I am using an async, away call; as well. I have read about the iOS version also: StackOverFlow/73805219 How I can fix this in Xamarin forms?
I must say that I am using Geolocalization from #Xamarin.Forms.Essentials to get the current longitud and latitude in an async function that I send by #MessaginCenter.
async Task StoringNoteAsync()
{
Location location = await _geolocation.GetCurrentLocation();
NoteSelected = NoteSelected ?? new Note();
NoteSelected.Title = Title;
NoteSelected.Content = Content;
NoteSelected.CreatedAt = DateTime.Now;
NoteSelected.iNoteType = (int)SelectedNoteType;
NoteSelected.Longitude = location.Longitude;
NoteSelected.Latitude = location.Latitude;
//_noteService.SaveNote( NoteSelected );
MessagingCenter.Instance.Send( this, "upsert", NoteSelected );
await _navigation.PopAsync();
}