cleanup: move internal/rbd/errors.go to internal/rbd/errors pacakge

Signed-off-by: Praveen M <m.praveen@ibm.com>
This commit is contained in:
Praveen M
2025-03-03 11:45:43 +05:30
committed by mergify[bot]
parent 9db0600941
commit 5cbc14454a
24 changed files with 251 additions and 155 deletions

View File

@ -19,6 +19,8 @@ package rbd
import (
"context"
"fmt"
rbderrors "github.com/ceph/ceph-csi/internal/rbd/errors"
)
// Sparsify checks the size of the objects in the RBD image and calls
@ -33,7 +35,7 @@ func (ri *rbdImage) Sparsify(_ context.Context) error {
}
if inUse {
// if the image is in use, we should not sparsify it, return ErrImageInUse.
return ErrImageInUse
return rbderrors.ErrImageInUse
}
image, err := ri.open()