This might be a niche question since Stitch is rather new, but I'll try anyway!
I have a Stitch app, with the MongoDB Connection String option enabled on the underlying Atlas cluster.
When trying to run this line in my code
const r = await collection.findOneAndDelete(filter);
I get the following error:
MongoError: unknown command findAndModify
at Connection.<anonymous> (node_modules/mongodb-core/lib/connection/pool.js:443:61)
at processMessage (node_modules/mongodb-core/lib/connection/connection.js:364:10)
at TLSSocket.<anonymous> (node_modules/mongodb-core/lib/connection/connection.js:533:15)
However, if I connect directly to the underlying Atlas cluster, this same code works fine.
I'm using MongoDB driver for NodeJS version 3.2.7
Did anyone encounter this, or can otherwise shed some light?