I'm using readFile to read a file but it seems that
dir.isFile() returns false even when it is a file.
After debugging isFile() reads muri which is returned something like this content://com.android.externalstorage.documents/tree/primary%3Aredacted/tree/primary%3Aredacted/.
file path passed is content://com.android.externalstorage.documents/tree/primary%3Aredacted/redacted--redacted.json.
I'm using
readFile
to read a file but it seems thatdir.isFile()
returns false even when it is a file.After debugging
isFile()
reads muri which is returned something like thiscontent://com.android.externalstorage.documents/tree/primary%3Aredacted/tree/primary%3Aredacted/
.file path passed is
content://com.android.externalstorage.documents/tree/primary%3Aredacted/redacted--redacted.json
.Please let me know if I'm doing anything wrong.