Skip to content
This repository has been archived by the owner on Jul 20, 2023. It is now read-only.

fix: preserve default values in x-goog-request-params header #210

Merged
merged 2 commits into from
Sep 14, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions src/v1/transcoder_service_client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -438,7 +438,7 @@ export class TranscoderServiceClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
parent: request.parent || '',
parent: request.parent ?? '',
});
this.initialize();
return this.innerApiCalls.createJob(request, options, callback);
Expand Down Expand Up @@ -524,7 +524,7 @@ export class TranscoderServiceClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
name: request.name || '',
name: request.name ?? '',
});
this.initialize();
return this.innerApiCalls.getJob(request, options, callback);
Expand Down Expand Up @@ -619,7 +619,7 @@ export class TranscoderServiceClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
name: request.name || '',
name: request.name ?? '',
});
this.initialize();
return this.innerApiCalls.deleteJob(request, options, callback);
Expand Down Expand Up @@ -725,7 +725,7 @@ export class TranscoderServiceClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
parent: request.parent || '',
parent: request.parent ?? '',
});
this.initialize();
return this.innerApiCalls.createJobTemplate(request, options, callback);
Expand Down Expand Up @@ -824,7 +824,7 @@ export class TranscoderServiceClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
name: request.name || '',
name: request.name ?? '',
});
this.initialize();
return this.innerApiCalls.getJobTemplate(request, options, callback);
Expand Down Expand Up @@ -925,7 +925,7 @@ export class TranscoderServiceClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
name: request.name || '',
name: request.name ?? '',
});
this.initialize();
return this.innerApiCalls.deleteJobTemplate(request, options, callback);
Expand Down Expand Up @@ -1031,7 +1031,7 @@ export class TranscoderServiceClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
parent: request.parent || '',
parent: request.parent ?? '',
});
this.initialize();
return this.innerApiCalls.listJobs(request, options, callback);
Expand Down Expand Up @@ -1076,7 +1076,7 @@ export class TranscoderServiceClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
parent: request.parent || '',
parent: request.parent ?? '',
});
const defaultCallSettings = this._defaults['listJobs'];
const callSettings = defaultCallSettings.merge(options);
Expand Down Expand Up @@ -1130,7 +1130,7 @@ export class TranscoderServiceClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
parent: request.parent || '',
parent: request.parent ?? '',
});
const defaultCallSettings = this._defaults['listJobs'];
const callSettings = defaultCallSettings.merge(options);
Expand Down Expand Up @@ -1242,7 +1242,7 @@ export class TranscoderServiceClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
parent: request.parent || '',
parent: request.parent ?? '',
});
this.initialize();
return this.innerApiCalls.listJobTemplates(request, options, callback);
Expand Down Expand Up @@ -1288,7 +1288,7 @@ export class TranscoderServiceClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
parent: request.parent || '',
parent: request.parent ?? '',
});
const defaultCallSettings = this._defaults['listJobTemplates'];
const callSettings = defaultCallSettings.merge(options);
Expand Down Expand Up @@ -1343,7 +1343,7 @@ export class TranscoderServiceClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
parent: request.parent || '',
parent: request.parent ?? '',
});
const defaultCallSettings = this._defaults['listJobTemplates'];
const callSettings = defaultCallSettings.merge(options);
Expand Down
Loading