Display photo URI from vcard when available

This commit is contained in:
Christophe Deschamps 2024-12-04 09:28:44 +01:00
parent 1ee6f6b2ef
commit c2d57c504f

View file

@ -408,7 +408,9 @@ private suspend fun loadContactPictureWithCoil(
)
} else {
val displayName = contact.contact.value?.name ?: contact.displayName.value.orEmpty()
val source = contact.contact.value?.getPictureUri(useThumbnail)
val source = contact.contact.value?.photo ?: contact.contact.value?.getPictureUri(
useThumbnail
)
val sourceStr = source.toString()
val base64 = if (ImageUtils.isBase64(sourceStr)) {
Log.d("[Coil] Picture URI is base64 encoded")