sloppy copypasta

This commit is contained in:
Megan Marsh 2018-01-10 10:08:23 -08:00
parent 898dadd53c
commit 55ddbf4765
1 changed files with 3 additions and 3 deletions

View File

@ -73,9 +73,9 @@ func DownloadableURL(original string) (string, error) {
if runtime.GOOS == "windows" {
// If the path is using Windows-style slashes, URL parses
// it into the host field.
if url.Path == "" && strings.Contains(url.Host, `\`) {
url.Path = url.Host
url.Host = ""
if u.Path == "" && strings.Contains(u.Host, `\`) {
u.Path = u.Host
u.Host = ""
}
}
// Only do the filepath transformations if the file appears