Skip to content

Commit

Permalink
GCP provider: adding a field mask to omit any unneeded information fr…
Browse files Browse the repository at this point in the history
…om regions.get response (#1849)
  • Loading branch information
LiorLieberman authored Mar 6, 2024
1 parent e31c11c commit f3e9ae7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion providers/gcp/gcp_provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ func getRegion(project, regionName string) *compute.Region {
log.Println(err)
return &compute.Region{}
}
region, err := computeService.Regions.Get(project, regionName).Do()
regionsGetCall := computeService.Regions.Get(project, regionName).Fields("name", "zones")
region, err := regionsGetCall.Do()
if err != nil {
log.Println(err)
return &compute.Region{}
Expand Down

0 comments on commit f3e9ae7

Please sign in to comment.