This was an addition to the URL spec, see: https://github.com/whatwg/url/commit/58acb0
strip_trailing_spaces_from_an_opaque_path()