Mongodb Function: _id (ObjectId) missing in query aggregate results

It’s working fine in the playground, only when being run in the Atlas Function is it failing.

I’m converting the aggregate with a toArray() method.