diff --git a/server/upload/internal/logic/uploadlogologic.go b/server/upload/internal/logic/uploadlogologic.go index 074c3d3f..0019177a 100644 --- a/server/upload/internal/logic/uploadlogologic.go +++ b/server/upload/internal/logic/uploadlogologic.go @@ -88,6 +88,7 @@ func (l *UploadLogoLogic) UploadLogo(req *types.UploadLogoReq, userinfo *auth.Us imageTypes["image/tiff"] = struct{}{} imageTypes["image/webp"] = struct{}{} imageTypes["image/svg+xml"] = struct{}{} + // 判断文件类型是否为图片 _, ok := imageTypes[fileType] if !ok {