mirror of
https://github.com/vmware-tanzu/velero.git
synced 2026-09-13 11:34:54 +00:00
Combine both daemonset lookup errors (windows retained as secondary)
Co-authored-by: kaovilai <11228024+kaovilai@users.noreply.github.com>
This commit is contained in:
co-authored by
kaovilai
parent
ef5375e3e3
commit
da01c1ca95
@@ -100,9 +100,7 @@ func IsReady(ctx context.Context, namespace string, crClient ctrlclient.Client)
|
||||
if err := crClient.Get(ctx, ctrlclient.ObjectKey{Namespace: namespace, Name: daemonsetWindows}, dsWindows); err != nil {
|
||||
dsWindows = nil
|
||||
if !apierrors.IsNotFound(err) {
|
||||
if lookupErr == nil {
|
||||
lookupErr = errors.Wrap(err, "failed to get windows node-agent daemonset")
|
||||
}
|
||||
lookupErr = errors.CombineErrors(lookupErr, errors.Wrap(err, "failed to get windows node-agent daemonset"))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user