package watch_graph //nolint:staticcheck

import (
	corev1 "gitlab.com/gitlab-org/cluster-integration/gitlab-agent/v18/internal/module/kubernetes_api/agent/watch_graph/vendored/k8s.io/api/core/v1"
	"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
)

func (vx *wgObject2vertex) collectPersistentVolumeClaimV1(obj *unstructured.Unstructured) *Error {
	o, err := unstructuredToTyped[corev1.PersistentVolumeClaim](obj)
	if err != nil {
		return err
	}
	vx.collectPersistentVolumeClaimV1Arcs(o, ReferenceArcType)
	return nil
}
