diff --git a/.changelog/4502.txt b/.changelog/4502.txt new file mode 100644 index 00000000000..c4a92c8ae64 --- /dev/null +++ b/.changelog/4502.txt @@ -0,0 +1,3 @@ +```release-note:bug + compute : fixed a bug where `guest_flush` could not be set to false for the resource `google_compute_resource_policy` +``` diff --git a/google/resource_compute_resource_policy.go b/google/resource_compute_resource_policy.go index 9c1099d236a..b45a621e530 100644 --- a/google/resource_compute_resource_policy.go +++ b/google/resource_compute_resource_policy.go @@ -1032,7 +1032,7 @@ func expandComputeResourcePolicySnapshotSchedulePolicySnapshotProperties(v inter transformedGuestFlush, err := expandComputeResourcePolicySnapshotSchedulePolicySnapshotPropertiesGuestFlush(original["guest_flush"], d, config) if err != nil { return nil, err - } else if val := reflect.ValueOf(transformedGuestFlush); val.IsValid() && !isEmptyValue(val) { + } else { transformed["guestFlush"] = transformedGuestFlush }