I’m trying to get devices contact list. When run app on browser I can see the logs in promise, when run on device I can’t see the logs. I’m running the app on android 5.1 and use chrome inspect device to see the logs.
public loadContactsFromDevice(): void {
console.log('ContactsProvider loadContactsFromDevice INIZIO');//this is fired
this.contacts.find(
['displayName', 'name', 'birthday'],
{filter: "", multiple: true})
.then(resultData => {
console.log('ContactsProvider loadContactsFromDevice resultData:' +resultData);//this is not fired
this.allContacts = resultData;//this is fired
this.setContactsList(this.allContacts);//this is fired
})
.catch(err => console.error("Error loading my data", err));
console.log('ContactsProvider loadContactsFromDevice FINE');//this is fired
}