Clean up slash suffix on -host value

pull/522/head
Jeff Mitchell 6 years ago
parent c3b4337b91
commit bf30a735dc

@ -799,6 +799,7 @@ func (c *Command) handleExec(passthroughArgs []string) {
}
var uri string
if c.flagHttpHost != "" {
c.flagHttpHost = strings.TrimSuffix(c.flagHttpHost, "/")
args = append(args, "-H", fmt.Sprintf("Host: %s", c.flagHttpHost))
args = append(args, "--resolve", fmt.Sprintf("%s:%s:%s", c.flagHttpHost, port, ip))
uri = fmt.Sprintf("%s://%s:%s", c.flagHttpScheme, c.flagHttpHost, port)

Loading…
Cancel
Save