Cleanup PathExists callers

This commit is contained in:
danielqsj
2019-01-08 22:08:00 +08:00
parent d94cd822b7
commit 8092904e3c
18 changed files with 33 additions and 31 deletions

View File

@@ -848,7 +848,7 @@ func (c *rbdUnmounter) TearDown() error {
func (c *rbdUnmounter) TearDownAt(dir string) error {
klog.V(4).Infof("rbd: attempting to teardown at %s", dir)
if pathExists, pathErr := volutil.PathExists(dir); pathErr != nil {
if pathExists, pathErr := mount.PathExists(dir); pathErr != nil {
return fmt.Errorf("Error checking if path exists: %v", pathErr)
} else if !pathExists {
klog.Warningf("Warning: Unmount skipped because path does not exist: %v", dir)