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

Commit 9f7b15d

Browse files
fix: preserve default values in x-goog-request-params header (#588)
- [ ] Regenerate this pull request now. PiperOrigin-RevId: 474338479 Source-Link: googleapis/googleapis@d5d35e0 Source-Link: https://github.com/googleapis/googleapis-gen/commit/efcd3f93962a103f68f003e2a1eecde6fa216a27 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiZWZjZDNmOTM5NjJhMTAzZjY4ZjAwM2UyYTFlZWNkZTZmYTIxNmEyNyJ9
1 parent ac79c4a commit 9f7b15d

4 files changed

Lines changed: 1242 additions & 1242 deletions

File tree

src/v1/cloud_redis_client.ts

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -572,7 +572,7 @@ export class CloudRedisClient {
572572
options.otherArgs.headers = options.otherArgs.headers || {};
573573
options.otherArgs.headers['x-goog-request-params'] =
574574
this._gaxModule.routingHeader.fromParams({
575-
name: request.name || '',
575+
name: request.name ?? '',
576576
});
577577
this.initialize();
578578
return this.innerApiCalls.getInstance(request, options, callback);
@@ -667,7 +667,7 @@ export class CloudRedisClient {
667667
options.otherArgs.headers = options.otherArgs.headers || {};
668668
options.otherArgs.headers['x-goog-request-params'] =
669669
this._gaxModule.routingHeader.fromParams({
670-
name: request.name || '',
670+
name: request.name ?? '',
671671
});
672672
this.initialize();
673673
return this.innerApiCalls.getInstanceAuthString(request, options, callback);
@@ -795,7 +795,7 @@ export class CloudRedisClient {
795795
options.otherArgs.headers = options.otherArgs.headers || {};
796796
options.otherArgs.headers['x-goog-request-params'] =
797797
this._gaxModule.routingHeader.fromParams({
798-
parent: request.parent || '',
798+
parent: request.parent ?? '',
799799
});
800800
this.initialize();
801801
return this.innerApiCalls.createInstance(request, options, callback);
@@ -948,7 +948,7 @@ export class CloudRedisClient {
948948
options.otherArgs.headers = options.otherArgs.headers || {};
949949
options.otherArgs.headers['x-goog-request-params'] =
950950
this._gaxModule.routingHeader.fromParams({
951-
'instance.name': request.instance!.name || '',
951+
'instance.name': request.instance!.name ?? '',
952952
});
953953
this.initialize();
954954
return this.innerApiCalls.updateInstance(request, options, callback);
@@ -1091,7 +1091,7 @@ export class CloudRedisClient {
10911091
options.otherArgs.headers = options.otherArgs.headers || {};
10921092
options.otherArgs.headers['x-goog-request-params'] =
10931093
this._gaxModule.routingHeader.fromParams({
1094-
name: request.name || '',
1094+
name: request.name ?? '',
10951095
});
10961096
this.initialize();
10971097
return this.innerApiCalls.upgradeInstance(request, options, callback);
@@ -1240,7 +1240,7 @@ export class CloudRedisClient {
12401240
options.otherArgs.headers = options.otherArgs.headers || {};
12411241
options.otherArgs.headers['x-goog-request-params'] =
12421242
this._gaxModule.routingHeader.fromParams({
1243-
name: request.name || '',
1243+
name: request.name ?? '',
12441244
});
12451245
this.initialize();
12461246
return this.innerApiCalls.importInstance(request, options, callback);
@@ -1387,7 +1387,7 @@ export class CloudRedisClient {
13871387
options.otherArgs.headers = options.otherArgs.headers || {};
13881388
options.otherArgs.headers['x-goog-request-params'] =
13891389
this._gaxModule.routingHeader.fromParams({
1390-
name: request.name || '',
1390+
name: request.name ?? '',
13911391
});
13921392
this.initialize();
13931393
return this.innerApiCalls.exportInstance(request, options, callback);
@@ -1531,7 +1531,7 @@ export class CloudRedisClient {
15311531
options.otherArgs.headers = options.otherArgs.headers || {};
15321532
options.otherArgs.headers['x-goog-request-params'] =
15331533
this._gaxModule.routingHeader.fromParams({
1534-
name: request.name || '',
1534+
name: request.name ?? '',
15351535
});
15361536
this.initialize();
15371537
return this.innerApiCalls.failoverInstance(request, options, callback);
@@ -1672,7 +1672,7 @@ export class CloudRedisClient {
16721672
options.otherArgs.headers = options.otherArgs.headers || {};
16731673
options.otherArgs.headers['x-goog-request-params'] =
16741674
this._gaxModule.routingHeader.fromParams({
1675-
name: request.name || '',
1675+
name: request.name ?? '',
16761676
});
16771677
this.initialize();
16781678
return this.innerApiCalls.deleteInstance(request, options, callback);
@@ -1819,7 +1819,7 @@ export class CloudRedisClient {
18191819
options.otherArgs.headers = options.otherArgs.headers || {};
18201820
options.otherArgs.headers['x-goog-request-params'] =
18211821
this._gaxModule.routingHeader.fromParams({
1822-
name: request.name || '',
1822+
name: request.name ?? '',
18231823
});
18241824
this.initialize();
18251825
return this.innerApiCalls.rescheduleMaintenance(request, options, callback);
@@ -1963,7 +1963,7 @@ export class CloudRedisClient {
19631963
options.otherArgs.headers = options.otherArgs.headers || {};
19641964
options.otherArgs.headers['x-goog-request-params'] =
19651965
this._gaxModule.routingHeader.fromParams({
1966-
parent: request.parent || '',
1966+
parent: request.parent ?? '',
19671967
});
19681968
this.initialize();
19691969
return this.innerApiCalls.listInstances(request, options, callback);
@@ -2010,7 +2010,7 @@ export class CloudRedisClient {
20102010
options.otherArgs.headers = options.otherArgs.headers || {};
20112011
options.otherArgs.headers['x-goog-request-params'] =
20122012
this._gaxModule.routingHeader.fromParams({
2013-
parent: request.parent || '',
2013+
parent: request.parent ?? '',
20142014
});
20152015
const defaultCallSettings = this._defaults['listInstances'];
20162016
const callSettings = defaultCallSettings.merge(options);
@@ -2066,7 +2066,7 @@ export class CloudRedisClient {
20662066
options.otherArgs.headers = options.otherArgs.headers || {};
20672067
options.otherArgs.headers['x-goog-request-params'] =
20682068
this._gaxModule.routingHeader.fromParams({
2069-
parent: request.parent || '',
2069+
parent: request.parent ?? '',
20702070
});
20712071
const defaultCallSettings = this._defaults['listInstances'];
20722072
const callSettings = defaultCallSettings.merge(options);

src/v1beta1/cloud_redis_client.ts

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -574,7 +574,7 @@ export class CloudRedisClient {
574574
options.otherArgs.headers = options.otherArgs.headers || {};
575575
options.otherArgs.headers['x-goog-request-params'] =
576576
this._gaxModule.routingHeader.fromParams({
577-
name: request.name || '',
577+
name: request.name ?? '',
578578
});
579579
this.initialize();
580580
return this.innerApiCalls.getInstance(request, options, callback);
@@ -675,7 +675,7 @@ export class CloudRedisClient {
675675
options.otherArgs.headers = options.otherArgs.headers || {};
676676
options.otherArgs.headers['x-goog-request-params'] =
677677
this._gaxModule.routingHeader.fromParams({
678-
name: request.name || '',
678+
name: request.name ?? '',
679679
});
680680
this.initialize();
681681
return this.innerApiCalls.getInstanceAuthString(request, options, callback);
@@ -803,7 +803,7 @@ export class CloudRedisClient {
803803
options.otherArgs.headers = options.otherArgs.headers || {};
804804
options.otherArgs.headers['x-goog-request-params'] =
805805
this._gaxModule.routingHeader.fromParams({
806-
parent: request.parent || '',
806+
parent: request.parent ?? '',
807807
});
808808
this.initialize();
809809
return this.innerApiCalls.createInstance(request, options, callback);
@@ -956,7 +956,7 @@ export class CloudRedisClient {
956956
options.otherArgs.headers = options.otherArgs.headers || {};
957957
options.otherArgs.headers['x-goog-request-params'] =
958958
this._gaxModule.routingHeader.fromParams({
959-
'instance.name': request.instance!.name || '',
959+
'instance.name': request.instance!.name ?? '',
960960
});
961961
this.initialize();
962962
return this.innerApiCalls.updateInstance(request, options, callback);
@@ -1099,7 +1099,7 @@ export class CloudRedisClient {
10991099
options.otherArgs.headers = options.otherArgs.headers || {};
11001100
options.otherArgs.headers['x-goog-request-params'] =
11011101
this._gaxModule.routingHeader.fromParams({
1102-
name: request.name || '',
1102+
name: request.name ?? '',
11031103
});
11041104
this.initialize();
11051105
return this.innerApiCalls.upgradeInstance(request, options, callback);
@@ -1248,7 +1248,7 @@ export class CloudRedisClient {
12481248
options.otherArgs.headers = options.otherArgs.headers || {};
12491249
options.otherArgs.headers['x-goog-request-params'] =
12501250
this._gaxModule.routingHeader.fromParams({
1251-
name: request.name || '',
1251+
name: request.name ?? '',
12521252
});
12531253
this.initialize();
12541254
return this.innerApiCalls.importInstance(request, options, callback);
@@ -1395,7 +1395,7 @@ export class CloudRedisClient {
13951395
options.otherArgs.headers = options.otherArgs.headers || {};
13961396
options.otherArgs.headers['x-goog-request-params'] =
13971397
this._gaxModule.routingHeader.fromParams({
1398-
name: request.name || '',
1398+
name: request.name ?? '',
13991399
});
14001400
this.initialize();
14011401
return this.innerApiCalls.exportInstance(request, options, callback);
@@ -1539,7 +1539,7 @@ export class CloudRedisClient {
15391539
options.otherArgs.headers = options.otherArgs.headers || {};
15401540
options.otherArgs.headers['x-goog-request-params'] =
15411541
this._gaxModule.routingHeader.fromParams({
1542-
name: request.name || '',
1542+
name: request.name ?? '',
15431543
});
15441544
this.initialize();
15451545
return this.innerApiCalls.failoverInstance(request, options, callback);
@@ -1665,7 +1665,7 @@ export class CloudRedisClient {
16651665
options.otherArgs.headers = options.otherArgs.headers || {};
16661666
options.otherArgs.headers['x-goog-request-params'] =
16671667
this._gaxModule.routingHeader.fromParams({
1668-
name: request.name || '',
1668+
name: request.name ?? '',
16691669
});
16701670
this.initialize();
16711671
return this.innerApiCalls.deleteInstance(request, options, callback);
@@ -1809,7 +1809,7 @@ export class CloudRedisClient {
18091809
options.otherArgs.headers = options.otherArgs.headers || {};
18101810
options.otherArgs.headers['x-goog-request-params'] =
18111811
this._gaxModule.routingHeader.fromParams({
1812-
name: request.name || '',
1812+
name: request.name ?? '',
18131813
});
18141814
this.initialize();
18151815
return this.innerApiCalls.rescheduleMaintenance(request, options, callback);
@@ -1959,7 +1959,7 @@ export class CloudRedisClient {
19591959
options.otherArgs.headers = options.otherArgs.headers || {};
19601960
options.otherArgs.headers['x-goog-request-params'] =
19611961
this._gaxModule.routingHeader.fromParams({
1962-
parent: request.parent || '',
1962+
parent: request.parent ?? '',
19631963
});
19641964
this.initialize();
19651965
return this.innerApiCalls.listInstances(request, options, callback);
@@ -2006,7 +2006,7 @@ export class CloudRedisClient {
20062006
options.otherArgs.headers = options.otherArgs.headers || {};
20072007
options.otherArgs.headers['x-goog-request-params'] =
20082008
this._gaxModule.routingHeader.fromParams({
2009-
parent: request.parent || '',
2009+
parent: request.parent ?? '',
20102010
});
20112011
const defaultCallSettings = this._defaults['listInstances'];
20122012
const callSettings = defaultCallSettings.merge(options);
@@ -2062,7 +2062,7 @@ export class CloudRedisClient {
20622062
options.otherArgs.headers = options.otherArgs.headers || {};
20632063
options.otherArgs.headers['x-goog-request-params'] =
20642064
this._gaxModule.routingHeader.fromParams({
2065-
parent: request.parent || '',
2065+
parent: request.parent ?? '',
20662066
});
20672067
const defaultCallSettings = this._defaults['listInstances'];
20682068
const callSettings = defaultCallSettings.merge(options);

0 commit comments

Comments
 (0)