add a check if the owner file from extended details exists
This commit is contained in:
parent
b1019af51b
commit
883e3ad6c1
|
@ -20,6 +20,9 @@ abstract class ViewPagerFragment : Fragment() {
|
||||||
|
|
||||||
fun getMediumExtendedDetails(medium: Medium): String {
|
fun getMediumExtendedDetails(medium: Medium): String {
|
||||||
val file = File(medium.path)
|
val file = File(medium.path)
|
||||||
|
if (!file.exists())
|
||||||
|
return ""
|
||||||
|
|
||||||
val path = "${file.parent.trimEnd('/')}/"
|
val path = "${file.parent.trimEnd('/')}/"
|
||||||
val exif = android.media.ExifInterface(medium.path)
|
val exif = android.media.ExifInterface(medium.path)
|
||||||
val details = StringBuilder()
|
val details = StringBuilder()
|
||||||
|
|
Loading…
Reference in New Issue