File tree Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ export class JsonKeyValueAdapter implements IKeyValueAdapter {
2525 if ( ! setting . value ) {
2626 throw new Error ( "Unexpected empty value for application/json content type." ) ;
2727 }
28- let parsedValue : any ;
28+ let parsedValue : unknown ;
2929 try {
3030 parsedValue = JSON . parse ( setting . value ) ;
3131 } catch ( error ) {
@@ -42,9 +42,9 @@ function isJsonContentType(contentTypeValue: string): boolean {
4242 return false ;
4343 }
4444
45- let contentTypeNormalized : string = contentTypeValue . trim ( ) . toLowerCase ( ) ;
46- let mimeType : string = contentTypeNormalized . split ( ";" , 1 ) [ 0 ] . trim ( ) ;
47- let typeParts : string [ ] = mimeType . split ( "/" ) ;
45+ const contentTypeNormalized : string = contentTypeValue . trim ( ) . toLowerCase ( ) ;
46+ const mimeType : string = contentTypeNormalized . split ( ";" , 1 ) [ 0 ] . trim ( ) ;
47+ const typeParts : string [ ] = mimeType . split ( "/" ) ;
4848 if ( typeParts . length !== 2 ) {
4949 return false ;
5050 }
Original file line number Diff line number Diff line change @@ -15,12 +15,12 @@ const {
1515
1616const jsonKeyValue = {
1717 value : '{"Test":{"Level":"Debug"},"Prod":{"Level":"Warning"}}' ,
18- key : ' json.settings.logging' ,
18+ key : " json.settings.logging" ,
1919 label : null ,
20- contentType : ' application/json' ,
21- lastModified : ' 2023-05-04T04:32:56.000Z' ,
20+ contentType : " application/json" ,
21+ lastModified : " 2023-05-04T04:32:56.000Z" ,
2222 tags : { } ,
23- etag : ' GdmsLWq3mFjFodVEXUYRmvFr3l_qRiKAW_KdpFbxZKk' ,
23+ etag : " GdmsLWq3mFjFodVEXUYRmvFr3l_qRiKAW_KdpFbxZKk" ,
2424 isReadOnly : false
2525} ;
2626const keyVaultKeyValue = createMockedKeyVaultReference ( "TestKey" , "https://fake-vault-name.vault.azure.net/secrets/fakeSecretName" ) ;
You can’t perform that action at this time.
0 commit comments