Skip to content

Commit da99ad5

Browse files
fix: preserve default values in x-goog-request-params header (#3353)
- [ ] Regenerate this pull request now. PiperOrigin-RevId: 474338479 Source-Link: googleapis/googleapis@d5d35e0 Source-Link: googleapis/googleapis-gen@efcd3f9 Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWFwaS1hcGlrZXlzLy5Pd2xCb3QueWFtbCIsImgiOiJlZmNkM2Y5Mzk2MmExMDNmNjhmMDAzZTJhMWVlY2RlNmZhMjE2YTI3In0= Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWJhdGNoLy5Pd2xCb3QueWFtbCIsImgiOiJlZmNkM2Y5Mzk2MmExMDNmNjhmMDAzZTJhMWVlY2RlNmZhMjE2YTI3In0= Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWJleW9uZGNvcnAtYXBwY29ubmVjdGlvbnMvLk93bEJvdC55YW1sIiwiaCI6ImVmY2QzZjkzOTYyYTEwM2Y2OGYwMDNlMmExZWVjZGU2ZmEyMTZhMjcifQ== Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWJleW9uZGNvcnAtYXBwY29ubmVjdG9ycy8uT3dsQm90LnlhbWwiLCJoIjoiZWZjZDNmOTM5NjJhMTAzZjY4ZjAwM2UyYTFlZWNkZTZmYTIxNmEyNyJ9 Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWJleW9uZGNvcnAtYXBwZ2F0ZXdheXMvLk93bEJvdC55YW1sIiwiaCI6ImVmY2QzZjkzOTYyYTEwM2Y2OGYwMDNlMmExZWVjZGU2ZmEyMTZhMjcifQ== Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWJleW9uZGNvcnAtY2xpZW50Y29ubmVjdG9yc2VydmljZXMvLk93bEJvdC55YW1sIiwiaCI6ImVmY2QzZjkzOTYyYTEwM2Y2OGYwMDNlMmExZWVjZGU2ZmEyMTZhMjcifQ== Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWJleW9uZGNvcnAtY2xpZW50Z2F0ZXdheXMvLk93bEJvdC55YW1sIiwiaCI6ImVmY2QzZjkzOTYyYTEwM2Y2OGYwMDNlMmExZWVjZGU2ZmEyMTZhMjcifQ== Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWdrZW11bHRpY2xvdWQvLk93bEJvdC55YW1sIiwiaCI6ImVmY2QzZjkzOTYyYTEwM2Y2OGYwMDNlMmExZWVjZGU2ZmEyMTZhMjcifQ== Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLXNlY3VyaXR5LXB1YmxpY2NhLy5Pd2xCb3QueWFtbCIsImgiOiJlZmNkM2Y5Mzk2MmExMDNmNjhmMDAzZTJhMWVlY2RlNmZhMjE2YTI3In0= Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWlhbS8uT3dsQm90LnlhbWwiLCJoIjoiZWZjZDNmOTM5NjJhMTAzZjY4ZjAwM2UyYTFlZWNkZTZmYTIxNmEyNyJ9
1 parent a9ee8c5 commit da99ad5

24 files changed

Lines changed: 4772 additions & 4531 deletions

File tree

packages/google-api-apikeys/src/v2/api_keys_client.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -497,7 +497,7 @@ export class ApiKeysClient {
497497
options.otherArgs.headers = options.otherArgs.headers || {};
498498
options.otherArgs.headers['x-goog-request-params'] =
499499
this._gaxModule.routingHeader.fromParams({
500-
name: request.name || '',
500+
name: request.name ?? '',
501501
});
502502
this.initialize();
503503
return this.innerApiCalls.getKey(request, options, callback);
@@ -583,7 +583,7 @@ export class ApiKeysClient {
583583
options.otherArgs.headers = options.otherArgs.headers || {};
584584
options.otherArgs.headers['x-goog-request-params'] =
585585
this._gaxModule.routingHeader.fromParams({
586-
name: request.name || '',
586+
name: request.name ?? '',
587587
});
588588
this.initialize();
589589
return this.innerApiCalls.getKeyString(request, options, callback);
@@ -787,7 +787,7 @@ export class ApiKeysClient {
787787
options.otherArgs.headers = options.otherArgs.headers || {};
788788
options.otherArgs.headers['x-goog-request-params'] =
789789
this._gaxModule.routingHeader.fromParams({
790-
parent: request.parent || '',
790+
parent: request.parent ?? '',
791791
});
792792
this.initialize();
793793
return this.innerApiCalls.createKey(request, options, callback);
@@ -936,7 +936,7 @@ export class ApiKeysClient {
936936
options.otherArgs.headers = options.otherArgs.headers || {};
937937
options.otherArgs.headers['x-goog-request-params'] =
938938
this._gaxModule.routingHeader.fromParams({
939-
'key.name': request.key!.name || '',
939+
'key.name': request.key!.name ?? '',
940940
});
941941
this.initialize();
942942
return this.innerApiCalls.updateKey(request, options, callback);
@@ -1078,7 +1078,7 @@ export class ApiKeysClient {
10781078
options.otherArgs.headers = options.otherArgs.headers || {};
10791079
options.otherArgs.headers['x-goog-request-params'] =
10801080
this._gaxModule.routingHeader.fromParams({
1081-
name: request.name || '',
1081+
name: request.name ?? '',
10821082
});
10831083
this.initialize();
10841084
return this.innerApiCalls.deleteKey(request, options, callback);
@@ -1216,7 +1216,7 @@ export class ApiKeysClient {
12161216
options.otherArgs.headers = options.otherArgs.headers || {};
12171217
options.otherArgs.headers['x-goog-request-params'] =
12181218
this._gaxModule.routingHeader.fromParams({
1219-
name: request.name || '',
1219+
name: request.name ?? '',
12201220
});
12211221
this.initialize();
12221222
return this.innerApiCalls.undeleteKey(request, options, callback);
@@ -1345,7 +1345,7 @@ export class ApiKeysClient {
13451345
options.otherArgs.headers = options.otherArgs.headers || {};
13461346
options.otherArgs.headers['x-goog-request-params'] =
13471347
this._gaxModule.routingHeader.fromParams({
1348-
parent: request.parent || '',
1348+
parent: request.parent ?? '',
13491349
});
13501350
this.initialize();
13511351
return this.innerApiCalls.listKeys(request, options, callback);
@@ -1386,7 +1386,7 @@ export class ApiKeysClient {
13861386
options.otherArgs.headers = options.otherArgs.headers || {};
13871387
options.otherArgs.headers['x-goog-request-params'] =
13881388
this._gaxModule.routingHeader.fromParams({
1389-
parent: request.parent || '',
1389+
parent: request.parent ?? '',
13901390
});
13911391
const defaultCallSettings = this._defaults['listKeys'];
13921392
const callSettings = defaultCallSettings.merge(options);
@@ -1436,7 +1436,7 @@ export class ApiKeysClient {
14361436
options.otherArgs.headers = options.otherArgs.headers || {};
14371437
options.otherArgs.headers['x-goog-request-params'] =
14381438
this._gaxModule.routingHeader.fromParams({
1439-
parent: request.parent || '',
1439+
parent: request.parent ?? '',
14401440
});
14411441
const defaultCallSettings = this._defaults['listKeys'];
14421442
const callSettings = defaultCallSettings.merge(options);

0 commit comments

Comments
 (0)