Using Angular's http client with complete in the subscribe (or the finalize pipe), the code is never executed.
Simple example:
this.http.get(myUrl).subscribe({
next: results => handleSuccess(results),
error: err => handleError(err),
complete: () => handleAllRequests()
The handleAllRequests()
function is never called. Adding the finalize pipe or an additional `.add() after the subscription per other answers does not work.
Similar questions: Angular 6 / Rxjs - how to basics: observables success, error, finally Angular HttpClient observable not completing