chore: rename errors
This commit is contained in:
@ -20,7 +20,7 @@ var UploadTaskManager = task.NewTaskManager[uint64](3, func(tid *uint64) {
|
||||
func Put(ctx context.Context, account driver.Driver, dstDirPath string, file model.FileStreamer) error {
|
||||
account, dstDirActualPath, err := operations.GetAccountAndActualPath(dstDirPath)
|
||||
if account.Config().NoUpload {
|
||||
return errors.WithStack(errs.ErrUploadNotSupported)
|
||||
return errors.WithStack(errs.UploadNotSupported)
|
||||
}
|
||||
if err != nil {
|
||||
return errors.WithMessage(err, "failed get account")
|
||||
|
@ -26,7 +26,7 @@ func Move(ctx context.Context, account driver.Driver, srcPath, dstDirPath string
|
||||
return errors.WithMessage(err, "failed get dst account")
|
||||
}
|
||||
if srcAccount.GetAccount() != dstAccount.GetAccount() {
|
||||
return errors.WithStack(errs.ErrMoveBetweenTwoAccounts)
|
||||
return errors.WithStack(errs.MoveBetweenTwoAccounts)
|
||||
}
|
||||
return operations.Move(ctx, account, srcActualPath, dstDirActualPath)
|
||||
}
|
||||
|
Reference in New Issue
Block a user