feat(worker): add image conversion endpoint and update file utility references in tasks

This commit is contained in:
keven1024
2026-02-27 14:38:31 +08:00
parent 7ca301e54d
commit 59cd23daf7
4 changed files with 5 additions and 6 deletions

View File

@@ -7,7 +7,6 @@ import (
"path/filepath"
"pkg/models"
u "pkg/utils"
"worker/internal/utils"
"github.com/hibiken/asynq"
)
@@ -36,7 +35,7 @@ func RemoveFile(ctx context.Context, task *asynq.Task) error {
}
rdb, rctx := u.GetRedisClient()
uploadPath, err := utils.GetUploadDirPath()
uploadPath, err := u.GetUploadDirPath()
if err != nil {
return err
}

View File

@@ -7,7 +7,6 @@ import (
"path/filepath"
"pkg/models"
u "pkg/utils"
"worker/internal/utils"
"github.com/hibiken/asynq"
"github.com/samber/lo"
@@ -32,7 +31,7 @@ func RemoveShare(ctx context.Context, task *asynq.Task) error {
})
if len(shareIDs) == 0 {
rdb, ctx := u.GetRedisClient()
uploadPath, err := utils.GetUploadDirPath()
uploadPath, err := u.GetUploadDirPath()
if err != nil {
return err
}