Skip to content

Commit

Permalink
Merge pull request #1251 from swagger-api/typescript-fetch-nullify
Browse files Browse the repository at this point in the history
nullify URL search field instead of delete
  • Loading branch information
HugoMario authored Feb 10, 2024
2 parents 419d417 + 7cde668 commit 40a2387
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/resources/handlebars/typescript-fetch/api.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ export class BaseAPI {
this.basePath = configuration.basePath || this.basePath;
}
}
};
}

/**
*
Expand Down Expand Up @@ -222,7 +222,7 @@ export const {{classname}}FetchParamCreator = function (configuration?: Configur
{{/bodyParam}}
localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query);
// fix override query string Detail: https://stackoverflow.com/a/7517673/1077943
delete localVarUrlObj.search;
localVarUrlObj.search = null;
localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers);
{{#hasFormParams}}
localVarRequestOptions.body = localVarFormParams.toString();
Expand Down

0 comments on commit 40a2387

Please sign in to comment.