load MyContactsCursor right at fetching

This commit is contained in:
tibbi 2022-02-07 11:23:16 +01:00
parent 5df251048f
commit 332725a9fc

View file

@ -479,7 +479,7 @@ fun Context.getMyContactsCursor(favoritesOnly: Boolean, withPhoneNumbersOnly: Bo
val getFavoritesOnly = if (favoritesOnly) "1" else "0"
val getWithPhoneNumbersOnly = if (withPhoneNumbersOnly) "1" else "0"
val args = arrayOf(getFavoritesOnly, getWithPhoneNumbersOnly)
CursorLoader(this, MyContactsContentProvider.CONTACTS_CONTENT_URI, null, null, args, null)
CursorLoader(this, MyContactsContentProvider.CONTACTS_CONTENT_URI, null, null, args, null).loadInBackground()
} catch (e: Exception) {
null
}