File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
src/schema-to-typescript/common Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -97,6 +97,7 @@ export function generateClient({
97
97
errorClassName,
98
98
generateJsDoc,
99
99
generateErrorJsDoc,
100
+ baseUrl,
100
101
...filenameConfig
101
102
} ,
102
103
generatedServiceImports,
@@ -163,7 +164,10 @@ export function generateClient({
163
164
memberExpression ( identifier ( commonHttpClientImportName ) , identifier ( commonHttpClientClassName ) ) ,
164
165
[
165
166
objectExpression ( [
166
- objectProperty ( identifier ( 'baseUrl' ) , stringLiteral ( servers [ 0 ] ?. url ?? defaultServerUrl ) ) ,
167
+ objectProperty (
168
+ identifier ( 'baseUrl' ) ,
169
+ stringLiteral ( baseUrl ?? servers [ 0 ] ?. url ?? defaultServerUrl )
170
+ ) ,
167
171
objectProperty ( identifier ( 'binaryResponseType' ) , stringLiteral ( responseBinaryType ) ) ,
168
172
objectProperty ( identifier ( 'errorClass' ) , identifier ( errorTypeName ) )
169
173
] )
You can’t perform that action at this time.
0 commit comments