diff --git a/samples/client/petstore/typescript-jquery/default/api/PetApi.ts b/samples/client/petstore/typescript-jquery/default/api/PetApi.ts index 3a2844ef25c..ef7f615f690 100644 --- a/samples/client/petstore/typescript-jquery/default/api/PetApi.ts +++ b/samples/client/petstore/typescript-jquery/default/api/PetApi.ts @@ -514,7 +514,7 @@ export class PetApi { formParams.append('additionalMetadata', additionalMetadata); } reqHasFile = true; - formParams.append("file", file); + formParams = file; // to determine the Content-Type header let consumes: string[] = [ 'multipart/form-data' diff --git a/samples/client/petstore/typescript-jquery/npm/api/PetApi.ts b/samples/client/petstore/typescript-jquery/npm/api/PetApi.ts index 3a2844ef25c..ef7f615f690 100644 --- a/samples/client/petstore/typescript-jquery/npm/api/PetApi.ts +++ b/samples/client/petstore/typescript-jquery/npm/api/PetApi.ts @@ -514,7 +514,7 @@ export class PetApi { formParams.append('additionalMetadata', additionalMetadata); } reqHasFile = true; - formParams.append("file", file); + formParams = file; // to determine the Content-Type header let consumes: string[] = [ 'multipart/form-data'