add .txt extension support
This commit is contained in:
父節點
8f51e7a8dc
當前提交
10855d554c
@ -8,7 +8,7 @@ import (
|
||||
func ValidateFilename(filename string) error {
|
||||
switch filepath.Ext(filename) {
|
||||
case ".pdf", ".doc", ".jpg", ".gif", ".png", ".jpeg",
|
||||
".docx", ".xls", ".xlsx", ".zip", ".rar", ".7z":
|
||||
".docx", ".xls", ".xlsx", ".zip", ".rar", ".7z", ".txt":
|
||||
return nil
|
||||
default:
|
||||
return errors.New("扩展名不支持")
|
||||
|
載入中…
x
新增問題並參考
Block a user