mirror of
https://github.com/halejohn/Cloudreve.git
synced 2026-01-26 09:34:57 +08:00
Feat: task queue / compression task
This commit is contained in:
@@ -75,7 +75,7 @@ func (service *DownloadService) DownloadArchived(ctx context.Context, c *gin.Con
|
||||
return serializer.Err(serializer.CodeNotSet, err.Error(), err)
|
||||
}
|
||||
|
||||
if fs.User.Group.OptionsSerialized.OneTimeDownloadEnabled {
|
||||
if fs.User.Group.OptionsSerialized.OneTimeDownload {
|
||||
// 清理资源,删除临时文件
|
||||
_ = cache.Deletes([]string{service.ID}, "archive_")
|
||||
}
|
||||
@@ -205,7 +205,7 @@ func (service *DownloadService) Download(ctx context.Context, c *gin.Context) se
|
||||
// 设置文件名
|
||||
c.Header("Content-Disposition", "attachment; filename=\""+url.PathEscape(fs.FileTarget[0].Name)+"\"")
|
||||
|
||||
if fs.User.Group.OptionsSerialized.OneTimeDownloadEnabled {
|
||||
if fs.User.Group.OptionsSerialized.OneTimeDownload {
|
||||
// 清理资源,删除临时文件
|
||||
_ = cache.Deletes([]string{service.ID}, "download_")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user