The code below works - but after i updated NODEJS from 4.. to 6.9.1 it suddently throws an error (for each call)...meaning it executes all recursive calls perfectly and afterwards tells me like 20 times the error message below...
"callback" argument must be a function.
I catch the error - and every thing works fine. Its a recursive call - filterTrades. I have been using it like this for a long time - and never had issues with it before. What to do? I guess the code use unnecessary resources to catch some thing (which actually isn't needed)?
var id = setImmediate(filterTrades(rows, indexStart, indexEnd, offset));
clearImmediate(id);