feat: add uri to aria2

This commit is contained in:
Noah Hsu
2022-06-21 17:37:02 +08:00
parent 55c4a925ba
commit f6242d46b1
7 changed files with 119 additions and 18 deletions

View File

@ -16,8 +16,8 @@ var UploadTaskManager = task.NewTaskManager[uint64, struct{}](3, func(tid *uint6
})
// Put add as a put task
func Put(ctx context.Context, account driver.Driver, dstDirPath string, file model.FileStreamer) error {
account, actualParentPath, err := operations.GetAccountAndActualPath(dstDirPath)
func Put(ctx context.Context, account driver.Driver, parentPath string, file model.FileStreamer) error {
account, actualParentPath, err := operations.GetAccountAndActualPath(parentPath)
if account.Config().NoUpload {
return errors.WithStack(ErrUploadNotSupported)
}