This commit is contained in:
jiangyong 2026-03-27 23:45:32 +08:00
parent 271a3579a1
commit d350e22c50
1 changed files with 1 additions and 1 deletions

View File

@ -124,7 +124,7 @@ func (s *Minio) Url(objectName string, expire time.Duration, https ...bool) stri
}
baseUrl := s.config.BaseUrl
if len(https) > 1 && https[0] {
if len(https) > 0 && https[0] {
if strings.HasPrefix(baseUrl, "http://") {
baseUrl = "https://" + strings.TrimPrefix(baseUrl, "http://")
}