lib/google/cloud/talent/v4beta1/event_service/client.rb in google-cloud-talent-v4beta1-0.4.3 vs lib/google/cloud/talent/v4beta1/event_service/client.rb in google-cloud-talent-v4beta1-0.4.4
- old
+ new
@@ -203,12 +203,14 @@
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
lib_name: @config.lib_name, lib_version: @config.lib_version,
gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
- header_params = {
- "parent" => request.parent
- }
+ header_params = {}
+ if request.parent
+ header_params["parent"] = request.parent
+ end
+
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
metadata[:"x-goog-request-params"] ||= request_params_header
options.apply_defaults timeout: @config.rpcs.create_client_event.timeout,
metadata: metadata,