lib/google/cloud/bigquery/copy_job.rb in google-cloud-bigquery-1.2.0 vs lib/google/cloud/bigquery/copy_job.rb in google-cloud-bigquery-1.3.0
- old
+ new
@@ -201,9 +201,14 @@
# copy_job.done? #=> true
#
# @!group Attributes
def location= value
@gapi.job_reference.location = value
+ return unless value.nil?
+
+ # Treat assigning value of nil the same as unsetting the value.
+ unset = @gapi.job_reference.instance_variables.include? :@location
+ @gapi.job_reference.remove_instance_variable :@location if unset
end
##
# Sets the create disposition.
#