File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed
Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -112,12 +112,12 @@ export class AWSClientBuilderV3 {
112112 public async createAwsService < C extends AwsClient > ( serviceOptions : AwsServiceOptions < C > ) : Promise < C > {
113113 const shim = this . getShim ( )
114114 const opt = ( serviceOptions . clientOptions ?? { } ) as AwsClientOptions
115-
115+ const userAgent = serviceOptions . userAgent ?? true
116116 if ( ! opt . region && serviceOptions . region ) {
117117 opt . region = serviceOptions . region
118118 }
119119
120- if ( ! opt . userAgent && serviceOptions . userAgent ) {
120+ if ( ! opt . userAgent && userAgent ) {
121121 opt . userAgent = [ [ getUserAgent ( { includePlatform : true , includeClientId : true } ) , extensionVersion ] ]
122122 }
123123
Original file line number Diff line number Diff line change @@ -16,9 +16,10 @@ export abstract class ClientWrapper<C extends AwsClient> implements vscode.Dispo
1616 ) { }
1717
1818 protected async getClient ( ignoreCache : boolean = false ) {
19+ const args = { serviceClient : this . clientType , region : this . regionCode }
1920 return ignoreCache
20- ? await globals . sdkClientBuilderV3 . createAwsService ( this . clientType , undefined , this . regionCode )
21- : await globals . sdkClientBuilderV3 . getAwsService ( this . clientType , undefined , this . regionCode )
21+ ? await globals . sdkClientBuilderV3 . createAwsService ( args )
22+ : await globals . sdkClientBuilderV3 . getAwsService ( args )
2223 }
2324
2425 protected async makeRequest < CommandInput extends object , Command extends AwsCommand > (
You can’t perform that action at this time.
0 commit comments