Browse Source

fix:前端oss上传时,需要后端返回相关配置

Roc 1 year ago
parent
commit
e315dd02fe
1 changed files with 2 additions and 2 deletions
  1. 2 2
      services/oss.go

+ 2 - 2
services/oss.go

@@ -154,7 +154,7 @@ func GetOssSTSToken() (item *STSToken, err error) {
 			item.ExpiredTime = lastToken.ExpiredTime
 			item.RegionId = utils.RegionId
 			item.Bucketname = utils.Bucketname
-			item.Endpoint = utils.Endpoint
+			item.Endpoint = utils.Imghost
 			item.Imghost = utils.Imghost
 			return
 		}
@@ -214,7 +214,7 @@ func NewSTSToken() (item *STSToken, err error) {
 		item.ExpiredTime = expiration.Format(utils.FormatDateTime)
 		item.RegionId = utils.RegionId
 		item.Bucketname = utils.Bucketname
-		item.Endpoint = utils.Endpoint
+		item.Endpoint = utils.Imghost
 		item.Imghost = utils.Imghost
 	}
 	return