fixing diskIsAttached func

This commit is contained in:
Divyen Patel 2018-02-14 07:03:43 -08:00
parent 78b60e2c1c
commit d7c02288fc

View File

@ -719,11 +719,10 @@ func diskIsAttached(volPath string, nodeName string) (bool, error) {
nodeName)
return false, err
}
if device != nil {
framework.Logf("diskIsAttached found the disk %q attached on node %q",
volPath,
nodeName)
if device == nil {
return false, nil
}
framework.Logf("diskIsAttached found the disk %q attached on node %q", volPath, nodeName)
return true, nil
}