forked from all_user/stat_center
初始化
This commit is contained in:
+2
-9
@@ -2,10 +2,8 @@ package fileApi
|
||||
|
||||
import (
|
||||
"stat/common/file"
|
||||
"stat/common/log"
|
||||
"stat/common/stdLog"
|
||||
"stat/statg"
|
||||
"strings"
|
||||
|
||||
"github.com/gin-gonic/gin"
|
||||
)
|
||||
@@ -32,13 +30,8 @@ func FileUpload(ctx *gin.Context) {
|
||||
})
|
||||
if err != nil {
|
||||
stdLog.ServerJSON(ctx, stdLog.Failure, err.Error())
|
||||
} else {
|
||||
|
||||
if !strings.HasPrefix(data, "v2/") {
|
||||
data = "v2/" + data
|
||||
}
|
||||
log.Error("file upload", log.Any("url", statg.Conf.ProxyUrl.FileRes), log.Any("path", data))
|
||||
stdLog.ServerJSON(ctx, stdLog.Success, data)
|
||||
}
|
||||
stdLog.ServerJSON(ctx, stdLog.Success, data)
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user