From 538240887b642f024574c8ed1503420f2b20e920 Mon Sep 17 00:00:00 2001 From: Valeri Karpov Date: Wed, 31 Mar 2021 13:38:14 -0400 Subject: [PATCH] fix(index.d.ts): add `transform` to PopulateOptions interface Fix #10061 --- index.d.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/index.d.ts b/index.d.ts index 31e43707499..5bd3928a3df 100644 --- a/index.d.ts +++ b/index.d.ts @@ -1036,6 +1036,8 @@ declare module 'mongoose' { * always set `path` to a document. Inferred from schema by default. */ justOne?: boolean; + /** transform function to call on every populated doc */ + transform?: (doc: any, id: any) => any; } interface ToObjectOptions {