Hi Ronald,
I think the backend is returning an array of header and not a single instance (and there is no children property in an array).
You can see what is returned in the console :
forkJoin ([mainHeaders, subHeaders]). subscribe (results => {
console.log ('results', results);
results [0] .children = results [1];
})
The take operator can also be useful in some cases:
forkJoin ([mainHeaders, subHeaders]). smoking pipe (
tap (result => console.log ('results', results)
) .subscribe (results => {
results [0] .children = results [1];
})
NB: there may be typos
Regards,
Arnaud.