Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
URLs with double slash at the start of the path fail to be requested #231
This seems to stem from this bit of code: https://github.com/rmccue/Requests/blob/master/library/Requests/IRI.php#L691-L694
I haven't looked at it close enough to determine if it's a logic error in the if statement, or if it's an edgecase it's specifically not attempting to support. At first I thought it was trying to catch the case where the scheme separator was picked up as the path component.
This was reported as a regression in WordPress 4.6, as we previously handled this scenario before we switched to Requests.
I'm unsure why this code exists here; I suspect it's an intricacy in the IRI spec. I didn't write this code however, this is ported from SimplePie's IRI parser, which was written by @gsnedders. I'm wondering if it's meant to be caught at a higher level.
We can probably fix this with no real issues.