Arguments that are posted in params can be optional, which is nice. But there's no handling if they're optional or not when sending a request.
This leads for a invalid query where the rest api back end can't handle the request.
For example:
getListOfNumbers$Response(params?: {
id?: number,
typeOfNumber?: string
}): Observable<StrictHttpResponse<Array<number>> {
const rb = new RequestBuilder(...);
if (params) {
rb.query('id', params.id);
rb.query('typeOfNumber', params.typeOfNumber);
}
// More code here...
}
Arguments that are posted in params can be optional, which is nice. But there's no handling if they're optional or not when sending a request. This leads for a invalid query where the rest api back end can't handle the request.
For example:
If we only request the id, the url would look something like this: http://backend-domain/numbers?id=1&typeOfNumber=
A proposal is to check these optional arguments like this: