-
Notifications
You must be signed in to change notification settings - Fork 123
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
Purl can fail to parse the fragment #66
Comments
Here is a fix that worked for me: arnaud-lb@67a6f61 |
Hi, Thanks for creating the issue and investigating the problem. Could you send a pull request for this change? |
peter279k
added a commit
to peter279k/purl
that referenced
this issue
Jun 24, 2018
Open
peter279k
added a commit
to peter279k/purl
that referenced
this issue
Jun 24, 2018
I tried this fix but it doesn't seem to work. I am not sure how to fix this at the moment. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Purl tries to parse fragments, but does not check for errors. When it happens, the fragment is completely missing from the stringified URL:
This script outputs this:
The problem is that in Fragment.php,
$this->data
is merged with the result ofparse_url($this->fragment)
. If parse_url returns false, array_merge returns null, and $this->data is null:purl/src/Purl/Fragment.php
Line 112 in 87bb711
The text was updated successfully, but these errors were encountered: