Could probably be simplified by using `URI.create(url).getPath()`