Merge pull request #12002 from hashicorp/paddy_catch_metadata_delete_error
provider/google: Check for errors when deleting project metadata.
This commit is contained in:
commit
672f496344
|
@ -192,6 +192,10 @@ func resourceComputeProjectMetadataDelete(d *schema.ResourceData, meta interface
|
||||||
|
|
||||||
op, err := config.clientCompute.Projects.SetCommonInstanceMetadata(projectID, md).Do()
|
op, err := config.clientCompute.Projects.SetCommonInstanceMetadata(projectID, md).Do()
|
||||||
|
|
||||||
|
if err != nil {
|
||||||
|
return fmt.Errorf("Error removing metadata from project %s: %s", projectID, err)
|
||||||
|
}
|
||||||
|
|
||||||
log.Printf("[DEBUG] SetCommonMetadata: %d (%s)", op.Id, op.SelfLink)
|
log.Printf("[DEBUG] SetCommonMetadata: %d (%s)", op.Id, op.SelfLink)
|
||||||
|
|
||||||
err = computeOperationWaitGlobal(config, op, project.Name, "SetCommonMetadata")
|
err = computeOperationWaitGlobal(config, op, project.Name, "SetCommonMetadata")
|
||||||
|
|
Loading…
Reference in New Issue