Browse Source

提交代码

tags/v1.22.6.2^2
ychao_1983 3 years ago
parent
commit
1c96138103
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      routers/repo/dataset.go

+ 2
- 2
routers/repo/dataset.go View File

@@ -172,8 +172,8 @@ func DatasetIndex(ctx *context.Context) {
for _, attachment := range pageAttachments {
uploader, _ := models.GetUserByID(attachment.UploaderID)
attachment.Uploader = uploader
if !strings.HasSuffix(attachment.Name, ".zip") {
attachment.DecompressState = -1 //非zip文件
if !strings.HasSuffix(attachment.Name, ".zip") && !strings.HasSuffix(attachment.Name, ".tar.gz") {
attachment.DecompressState = -1 //非压缩文件
}

}


Loading…
Cancel
Save