mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-29 22:03:55 +01:00
fixed warning
This commit is contained in:
parent
68c24c47e3
commit
6e929e3786
1 changed files with 190 additions and 189 deletions
|
|
@ -86,7 +86,7 @@ class FileProcessor
|
|||
*/
|
||||
fun getExifTagsToRedact(): Set<String> {
|
||||
val prefManageEXIFTags =
|
||||
defaultKvStore.getStringSet(Prefs.MANAGED_EXIF_TAGS) ?: emptySet()
|
||||
defaultKvStore.getStringSet(Prefs.MANAGED_EXIF_TAGS) ?: emptySet<String>()
|
||||
val redactTags: Set<String> =
|
||||
context.resources.getStringArray(R.array.pref_exifTag_values).toSet()
|
||||
return redactTags - prefManageEXIFTags
|
||||
|
|
@ -131,9 +131,10 @@ class FileProcessor
|
|||
?.getAttribute(tag)
|
||||
?.takeIf { it.isNotEmpty() }
|
||||
?.let { attributeName ->
|
||||
exifInterface.setAttribute(tag, null).also {
|
||||
Timber.d("Exif tag $tag with value $attributeName redacted.")
|
||||
exifInterface.setAttribute(tag, "").also {
|
||||
Timber.d("EXIF tag $tag removed or set to empty.")
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue