This commit is contained in:
laodaming 2023-06-13 10:03:09 +08:00
parent 69e2fd4362
commit 346023593d

View File

@ -2,7 +2,7 @@ package image
// 校验上传图片类型合法不合法 // 校验上传图片类型合法不合法
func CheckUploadImageFormat(fileName string) bool { func CheckUploadImageFormat(fileName string) bool {
switch ext { switch fileName {
case "jpg", "png", "fbx", "glb", "hdr", "jpeg", "svg", "pdf", "psd", "webp", "gif": case "jpg", "png", "fbx", "glb", "hdr", "jpeg", "svg", "pdf", "psd", "webp", "gif":
return true return true
} }