Skip to content

Commit

Permalink
fix: preserve default values in x-goog-request-params header (#66)
Browse files Browse the repository at this point in the history
- [ ] Regenerate this pull request now.

PiperOrigin-RevId: 474338479

Source-Link: googleapis/googleapis@d5d35e0

Source-Link: googleapis/googleapis-gen@efcd3f9
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiZWZjZDNmOTM5NjJhMTAzZjY4ZjAwM2UyYTFlZWNkZTZmYTIxNmEyNyJ9
  • Loading branch information
gcf-owl-bot[bot] authored Sep 14, 2022
1 parent 19fd47f commit c43164f
Show file tree
Hide file tree
Showing 2 changed files with 1,046 additions and 1,012 deletions.
52 changes: 26 additions & 26 deletions packages/google-cloud-deploy/src/v1/cloud_deploy_client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -657,7 +657,7 @@ export class CloudDeployClient {
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.getDeliveryPipeline(request, options, callback);
Expand Down Expand Up @@ -741,7 +741,7 @@ export class CloudDeployClient {
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.getTarget(request, options, callback);
Expand Down Expand Up @@ -825,7 +825,7 @@ export class CloudDeployClient {
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.getRelease(request, options, callback);
Expand Down Expand Up @@ -914,7 +914,7 @@ export class CloudDeployClient {
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.approveRollout(request, options, callback);
Expand Down Expand Up @@ -998,7 +998,7 @@ export class CloudDeployClient {
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.getRollout(request, options, callback);
Expand Down Expand Up @@ -1081,7 +1081,7 @@ export class CloudDeployClient {
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.getConfig(request, options, callback);
Expand Down Expand Up @@ -1207,7 +1207,7 @@ export class CloudDeployClient {
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.createDeliveryPipeline(
Expand Down Expand Up @@ -1375,7 +1375,7 @@ export class CloudDeployClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
'delivery_pipeline.name': request.deliveryPipeline!.name || '',
'delivery_pipeline.name': request.deliveryPipeline!.name ?? '',
});
this.initialize();
return this.innerApiCalls.updateDeliveryPipeline(
Expand Down Expand Up @@ -1546,7 +1546,7 @@ export class CloudDeployClient {
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.deleteDeliveryPipeline(
Expand Down Expand Up @@ -1711,7 +1711,7 @@ export class CloudDeployClient {
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.createTarget(request, options, callback);
Expand Down Expand Up @@ -1875,7 +1875,7 @@ export class CloudDeployClient {
options.otherArgs.headers = options.otherArgs.headers || {};
options.otherArgs.headers['x-goog-request-params'] =
this._gaxModule.routingHeader.fromParams({
'target.name': request.target!.name || '',
'target.name': request.target!.name ?? '',
});
this.initialize();
return this.innerApiCalls.updateTarget(request, options, callback);
Expand Down Expand Up @@ -2038,7 +2038,7 @@ export class CloudDeployClient {
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.deleteTarget(request, options, callback);
Expand Down Expand Up @@ -2199,7 +2199,7 @@ export class CloudDeployClient {
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.createRelease(request, options, callback);
Expand Down Expand Up @@ -2360,7 +2360,7 @@ export class CloudDeployClient {
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.createRollout(request, options, callback);
Expand Down Expand Up @@ -2506,7 +2506,7 @@ export class CloudDeployClient {
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.listDeliveryPipelines(request, options, callback);
Expand Down Expand Up @@ -2557,7 +2557,7 @@ export class CloudDeployClient {
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['listDeliveryPipelines'];
const callSettings = defaultCallSettings.merge(options);
Expand Down Expand Up @@ -2617,7 +2617,7 @@ export class CloudDeployClient {
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['listDeliveryPipelines'];
const callSettings = defaultCallSettings.merge(options);
Expand Down Expand Up @@ -2725,7 +2725,7 @@ export class CloudDeployClient {
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.listTargets(request, options, callback);
Expand Down Expand Up @@ -2775,7 +2775,7 @@ export class CloudDeployClient {
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['listTargets'];
const callSettings = defaultCallSettings.merge(options);
Expand Down Expand Up @@ -2834,7 +2834,7 @@ export class CloudDeployClient {
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['listTargets'];
const callSettings = defaultCallSettings.merge(options);
Expand Down Expand Up @@ -2943,7 +2943,7 @@ export class CloudDeployClient {
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.listReleases(request, options, callback);
Expand Down Expand Up @@ -2992,7 +2992,7 @@ export class CloudDeployClient {
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['listReleases'];
const callSettings = defaultCallSettings.merge(options);
Expand Down Expand Up @@ -3050,7 +3050,7 @@ export class CloudDeployClient {
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['listReleases'];
const callSettings = defaultCallSettings.merge(options);
Expand Down Expand Up @@ -3159,7 +3159,7 @@ export class CloudDeployClient {
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.listRollouts(request, options, callback);
Expand Down Expand Up @@ -3208,7 +3208,7 @@ export class CloudDeployClient {
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['listRollouts'];
const callSettings = defaultCallSettings.merge(options);
Expand Down Expand Up @@ -3266,7 +3266,7 @@ export class CloudDeployClient {
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['listRollouts'];
const callSettings = defaultCallSettings.merge(options);
Expand Down
Loading

0 comments on commit c43164f

Please sign in to comment.