huawei snapshot delete fix

This commit is contained in:
TangBin
2020-09-24 17:02:24 +08:00
parent 9a7eae6e03
commit faeb294d56
+1 -1
View File
@@ -199,7 +199,7 @@ func doListPart(doList listFunc, queries map[string]string, result interface{})
func DoGet(doGet getFunc, id string, queries map[string]string, result interface{}) error {
if len(id) == 0 {
resultType := reflect.Indirect(reflect.ValueOf(result)).Type()
return fmt.Errorf(" Get %s id should not be empty", resultType.Name())
return errors.Wrap(cloudprovider.ErrNotFound, fmt.Sprintf(" Get %s id should not be empty", resultType.Name()))
}
ret, err := doGet(id, queries)