Skip to content

Commit c3f9fdd

Browse files
author
Simeon Borko
committed
typescript-fetch: nullify URL search field instead of delete
1 parent 16f539d commit c3f9fdd

File tree

1 file changed

+2
-2
lines changed
  • modules/swagger-codegen/src/main/resources/typescript-fetch

1 file changed

+2
-2
lines changed

modules/swagger-codegen/src/main/resources/typescript-fetch/api.mustache

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ export class BaseAPI {
5252
this.basePath = configuration.basePath || this.basePath;
5353
}
5454
}
55-
};
55+
}
5656

5757
/**
5858
*
@@ -224,7 +224,7 @@ export const {{classname}}FetchParamCreator = function (configuration?: Configur
224224
{{/bodyParam}}
225225
localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query);
226226
// fix override query string Detail: https://stackoverflow.com/a/7517673/1077943
227-
delete localVarUrlObj.search;
227+
localVarUrlObj.search = null;
228228
localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers);
229229
{{#hasFormParams}}
230230
localVarRequestOptions.body = localVarFormParams.toString();

0 commit comments

Comments
 (0)