From 148ceb2e186f498235d7f9bdc8a1c6084c0a066c Mon Sep 17 00:00:00 2001 From: kubasobon Date: Tue, 23 Apr 2024 11:12:21 +0200 Subject: [PATCH] port GCP SubType fix --- internal/resources/fetching/fetchers/gcp/assets_fetcher.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/resources/fetching/fetchers/gcp/assets_fetcher.go b/internal/resources/fetching/fetchers/gcp/assets_fetcher.go index ea05d9bfac..fae147fff1 100644 --- a/internal/resources/fetching/fetchers/gcp/assets_fetcher.go +++ b/internal/resources/fetching/fetchers/gcp/assets_fetcher.go @@ -156,7 +156,7 @@ func (r *GcpAsset) GetElasticCommonData() (map[string]any, error) { m["user.effective.name"] = getAssetResourceName(r.ExtendedAsset) } - if r.Type == fetching.CloudCompute && r.SubType == inventory.ComputeInstanceAssetType { + if r.Type == fetching.CloudCompute && r.ExtendedAsset.AssetType == inventory.ComputeInstanceAssetType { fields := getAssetDataFields(r.ExtendedAsset) if fields == nil { return m, nil