Skip to content

Fixes issue with files name containing colon : #4

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

chaudharydeepanshu
Copy link
Contributor

If the file path passed is an absolute file path and if its name contains colon : then the URI parsed will be wrong as the scheme parsed will be not unusable.

More detail:-
Example path with issue: /data/user/0/com.example.appname/cache/2022-11-05 20:53:17.783069.png.
Now, for the example the parsedScheme in getURI will be /data/user/0/com.example.appname/cache/2022-11-05 20 as a scheme is anything before colon. Due to this getURI will return us the same string passed which will be unusable further down the code.

So, what we do is check if the string passed to getURI starts with / or not, if it starts with / then most probably it is an absolute file path.

Let me know if you have any questions about this change.

@chaudharydeepanshu
Copy link
Contributor Author

Any update on this guys?

@p-kuen
Copy link
Contributor

p-kuen commented Feb 3, 2023

Sorry, we had no time to look at your PR. We will try to review asap.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants