Merge pull request #573 from harshavardhana/pr_out_objecturl_in_s3client_should_construct_pathstyle_url

This commit is contained in:
Harshavardhana
2015-04-28 23:46:33 -07:00
+4
View File
@@ -143,6 +143,10 @@ func (c *s3Client) objectURL(bucket, object string) string {
if net.ParseIP(host) != nil {
return url + "/" + object
}
// if not amazon do not construct a subdomain URL
if !strings.Contains(c.Host, "amazonaws.com") {
return url + "/" + object
}
return url + object
}