Skip to content

Commit

Permalink
if includeFetchAdapter then set use fetch by default
Browse files Browse the repository at this point in the history
  • Loading branch information
dphuang2 committed Oct 11, 2023
1 parent 128b79c commit 0b1c067
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,6 @@ const {{{clientNameLowercase}}} = new {{{clientName}}}({
{{{apiDocumentationAuthenticationPartial}}}
{{/apiDocumentationAuthenticationPartial}}
{{^apiDocumentationAuthenticationPartial}}
{{#includeFetchAdapter}}
// Use native Fetch API instead of axios
// useFetch: true,
{{/includeFetchAdapter}}
{{> api_doc_example_setup_parameters}}
{{/apiDocumentationAuthenticationPartial}}
})
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ export class Configuration {
this.basePath = param.basePath;
this.baseOptions = param.baseOptions ?? {};
{{#includeFetchAdapter}}
if (param.useFetch) {
if (param.useFetch ?? true) {
this.baseOptions["adapter"] = fetchAdapter
}
{{/includeFetchAdapter}}
Expand Down

0 comments on commit 0b1c067

Please sign in to comment.