diff --git a/providers/gcp/resources/bigquery.go b/providers/gcp/resources/bigquery.go index b57a50ab0d..fed451ec95 100644 --- a/providers/gcp/resources/bigquery.go +++ b/providers/gcp/resources/bigquery.go @@ -190,6 +190,8 @@ func initGcpProjectBigqueryServiceDataset(runtime *plugin.Runtime, args map[stri args["id"] = llx.StringData(ids.name) args["location"] = llx.StringData(ids.region) args["projectId"] = llx.StringData(ids.project) + } else { + return nil, nil, errors.New("no asset identifier found") } } diff --git a/providers/gcp/resources/compute.go b/providers/gcp/resources/compute.go index b2d0bdb5d1..b093b2b50b 100644 --- a/providers/gcp/resources/compute.go +++ b/providers/gcp/resources/compute.go @@ -807,6 +807,8 @@ func initGcpProjectComputeServiceFirewall(runtime *plugin.Runtime, args map[stri if ids := getAssetIdentifier(runtime); ids != nil { args["name"] = llx.StringData(ids.name) args["projectId"] = llx.StringData(ids.project) + } else { + return nil, nil, errors.New("no asset identifier found") } } diff --git a/providers/gcp/resources/gke.go b/providers/gcp/resources/gke.go index 96ca81afed..a0849b625a 100644 --- a/providers/gcp/resources/gke.go +++ b/providers/gcp/resources/gke.go @@ -5,6 +5,7 @@ package resources import ( "context" + "errors" "fmt" "strings" @@ -62,6 +63,8 @@ func initGcpProjectGkeServiceCluster(runtime *plugin.Runtime, args map[string]*l args["name"] = llx.StringData(ids.name) args["location"] = llx.StringData(ids.region) args["projectId"] = llx.StringData(ids.project) + } else { + return nil, nil, errors.New("no asset identifier found") } } diff --git a/providers/gcp/resources/storage.go b/providers/gcp/resources/storage.go index b02c23ee76..d0f229a445 100644 --- a/providers/gcp/resources/storage.go +++ b/providers/gcp/resources/storage.go @@ -5,6 +5,7 @@ package resources import ( "context" + "errors" "fmt" "strconv" @@ -143,6 +144,8 @@ func initGcpProjectStorageServiceBucket(runtime *plugin.Runtime, args map[string args["name"] = llx.StringData(ids.name) args["projectId"] = llx.StringData(ids.project) args["location"] = llx.StringData(ids.region) + } else { + return nil, nil, errors.New("no asset identifier found") } }