From faeb294d5613e27e904d9458098c50bd16d8f9a4 Mon Sep 17 00:00:00 2001 From: TangBin Date: Thu, 24 Sep 2020 17:02:24 +0800 Subject: [PATCH] huawei snapshot delete fix --- pkg/multicloud/huawei/utils.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/multicloud/huawei/utils.go b/pkg/multicloud/huawei/utils.go index e3eed756f0..f05a2b47a3 100644 --- a/pkg/multicloud/huawei/utils.go +++ b/pkg/multicloud/huawei/utils.go @@ -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)