I want to remove the "_id" from all documents returned by MongoDB; this code does not work:
const res = await findPromise<Omit<TaleGroupDB, "_id">>(
"table1",
{ provider },
undefined,
proxy
);
Why does "Omit" not work?
The query returns record like
{_id: ObjectId, field1: "text1", field2: "test2"}
Expected result:
{field1: "text1", field2: "test2"}