refactor: 移除不必要的配置依赖,简化上传URL生成逻辑并添加公开访问URL支持
This commit is contained in:
@@ -4,7 +4,6 @@ import (
|
||||
"carrotskin/internal/model"
|
||||
"carrotskin/internal/service"
|
||||
"carrotskin/internal/types"
|
||||
"carrotskin/pkg/config"
|
||||
"carrotskin/pkg/database"
|
||||
"carrotskin/pkg/logger"
|
||||
"carrotskin/pkg/storage"
|
||||
@@ -38,11 +37,9 @@ func GenerateTextureUploadURL(c *gin.Context) {
|
||||
}
|
||||
|
||||
storageClient := storage.MustGetClient()
|
||||
cfg := *config.MustGetRustFSConfig()
|
||||
result, err := service.GenerateTextureUploadURL(
|
||||
c.Request.Context(),
|
||||
storageClient,
|
||||
cfg,
|
||||
userID,
|
||||
req.FileName,
|
||||
string(req.TextureType),
|
||||
|
||||
Reference in New Issue
Block a user