diff options
author | clsr <clsr@clsr.net> | 2016-06-21 16:34:16 +0200 |
---|---|---|
committer | clsr <clsr@clsr.net> | 2016-06-21 16:34:16 +0200 |
commit | c4670ac63db5b4496bb5d2f6795d7b99af57a762 (patch) | |
tree | 58d34b71d5d3e65d370aa11948ae5e4d05ec3b99 | |
parent | 26c6e8e8fb3a37344fba8438af54e2947a5e5b0b (diff) | |
download | gomf-c4670ac63db5b4496bb5d2f6795d7b99af57a762.tar.gz gomf-c4670ac63db5b4496bb5d2f6795d7b99af57a762.zip |
Prefer --upload-host for generated --upload-urlv0.2.6
-rw-r--r-- | main.go | 16 |
1 files changed, 8 insertions, 8 deletions
@@ -97,16 +97,16 @@ func main() { } if uploadUrl == "" { - if *listenHttps != "" { - if uploadHost != "" { + if uploadHost != "" { + if *listenHttps != "" { uploadUrl = "https://" + uploadHost + "/" - } else { - uploadUrl = "https://" + *listenHttps + "/u/" - } - } else if *listenHttp != "" { - if uploadHost != "" { + } else if *listenHttp != "" { uploadUrl = "http://" + uploadHost + "/" - } else { + } + } else { + if *listenHttps != "" { + uploadUrl = "https://" + *listenHttps + "/u/" + } else if *listenHttp != "" { uploadUrl = "http://" + *listenHttp + "/u/" } } |