Consider the following code snippet:
this.service1
.getValues()
.pipe(
mergeMap(response => this.service2.getMoreValues(response.id)),
catchError(err => of({}))
)
.subscribe(response) => {
console.log(response)
});
The issue I am facing is that if the catchError method is triggered, new values stop being received in my subscription. Ideally, I would like to return an empty object when catchError is called and continue normally, while still expecting new values from my services.
I'm wondering why the subscription stops working after catchError is invoked. Any insights would be greatly appreciated. Thank you.