upload: fix repos with non-null uriPath
This commit fixes the handling of repo URIs that have a non-null uriPath. Previously, the code would just override the uriPath if the repo had one. For example, "http://hackage.haskell.org/foo" as repo would lead to the upload URI "http://hackage.haskell.org/upload". Even using `parseRelativeReference "upload"` (instead of "/upload") doesn't work, since that will replace the last path component of the URI path (i.e. "/foo/bar" would generate the URI "/foo/upload", but we want "/foo/bar/upload").
Showing with 5 additions and 5 deletions