Closed J-GG closed 5 years ago
hmm, on the other hand if someone accessed /api/v0/user/username/files/path//home/username/foo.py
with the double slash, that would actually still work, even though that is "incorrect" and wasn't our intention. So I am inclined to accept the pull request. any thoughts?
Hmm, that's an interesting one. Technically speaking, the current docs are correct, and the proposed change is incorrect -- but I can certainly see why it's confusing.
The API endpoint is currently described as
So, if you want to download the file
/home/username/foo.py
, then the URL should be:With the proposed change, it would imply that the URL should be
...which is incorrect.
But yeah, it does look confusing as it is and I can imagine that someone not realising that all valid Unix absolute paths begin with a "/" would miss out the slash and get it wrong in the other direction.
Still not sure what the correct solution is, though.