I spend some time figuring out what was the problem with this
arr.filter((order)=>{
order.trackingNumbers.some((track)=>{
track.number==search
})
})
and then noticed that it works if is written in just one line
arr.filter(order=>order.trackingNumbers.some(track=>track.number==search))
why is that and is posible to write it on several lines?