diff --git a/crs/api/core/v1alpha1/global.go b/crs/api/core/v1alpha1/global.go index 2a45fbad..37d35e09 100644 --- a/crs/api/core/v1alpha1/global.go +++ b/crs/api/core/v1alpha1/global.go @@ -47,6 +47,7 @@ func (in *GlobalSpec) DeepCopyInto(out *GlobalSpec) { out.LogTargets = make([]*models.LogTarget, len(in.LogTargets)) for i, v := range in.LogTargets { b, _ := v.MarshalBinary() + out.LogTargets[i] = &models.LogTarget{} _ = out.LogTargets[i].UnmarshalBinary(b) } } diff --git a/crs/api/core/v1alpha2/global.go b/crs/api/core/v1alpha2/global.go index f006e071..f639f892 100644 --- a/crs/api/core/v1alpha2/global.go +++ b/crs/api/core/v1alpha2/global.go @@ -47,6 +47,7 @@ func (in *GlobalSpec) DeepCopyInto(out *GlobalSpec) { out.LogTargets = make([]*models.LogTarget, len(in.LogTargets)) for i, v := range in.LogTargets { b, _ := v.MarshalBinary() + out.LogTargets[i] = &models.LogTarget{} _ = out.LogTargets[i].UnmarshalBinary(b) } }