Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Running listFiles on a subdirectory uri creates a new folder #5

Closed
rembo10 opened this issue Sep 5, 2021 · 2 comments
Closed

Running listFiles on a subdirectory uri creates a new folder #5

rembo10 opened this issue Sep 5, 2021 · 2 comments
Labels
bug Something isn't working

Comments

@rembo10
Copy link
Contributor

rembo10 commented Sep 5, 2021

Hi.... I really like your library even through I'm running into a little issue. If I run listFiles on a document tree that I selected, and then run listFiles on one of the subdirectories that were returned, it seems to create a directory in the root document tree, instead of listing the files.

For example, I have a /sdcard/Bills directory. When I run openDocumentTree, and select that directory, it returns:
[{"lastModified": 1630735526000, "name": "Pending", "type": "directory", "uri": "content://com.android.externalstorage.documents/tree/primary%3Abills/document/primary%3ABills%2FPending"}]

If I run listFiles on that uri.... it creates an empty directory: /sdcard/bills/document/primary%3ABills%2FPending/

Is this a problem with my document picker? It's Files by Google v1.0.389363820

Thanks for the help

@ammarahm-ed
Copy link
Owner

Hey, thanks for reporting. I have fixed the issue. Can you try again using the master branch:

yarn add https://github.com/ammarahm-ed/react-native-scoped-storage.git

Let me know soon after so I can ship the fix inv1.4.0

@ammarahm-ed ammarahm-ed added the bug Something isn't working label Sep 5, 2021
@rembo10
Copy link
Contributor Author

rembo10 commented Sep 6, 2021

Wow, thanks for the fast reply. That seems to have done it! Thanks so much! I was using react-native-document-picker and react-native-fs before but I much prefer using this.

@rembo10 rembo10 closed this as completed Sep 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants